through vba only...
When I click browser button on my userform it opens the default folder of "my documents" to open any excel file
I need to open the default folder to be = "C:\my project\new" to open file from there...
through vba only...
When I click browser button on my userform it opens the default folder of "my documents" to open any excel file
I need to open the default folder to be = "C:\my project\new" to open file from there...
is it possible???
or my question is not cleared?????
Sub Open_Folder()
Dim MyPath As String
Dim SaveDriveDir As String
Dim FName As Variant
SaveDriveDir = CurDir
MyPath = "C:\my project\new"
ChDrive MyPath
ChDir MyPath
FName = Application.GetOpenFilename(filefilter:="Excel Files (*.xls),
*.xls", _
MultiSelect:=False)
'Do whatever you need to do with file....
ChDrive SaveDriveDir
ChDir SaveDriveDir
End Sub
This should get you started,
Mike F
"ilyaskazi" <[email protected]> wrote
in message news:[email protected]...
>
> through vba only...
>
> When I click browser button on my userform it opens the default folder
> of "my documents" to open any excel file
>
> I need to open the default folder to be = "C:\my project\new" to open
> file from there...
>
>
> --
> ilyaskazi
> ------------------------------------------------------------------------
> ilyaskazi's Profile:
> http://www.excelforum.com/member.php...o&userid=23969
> View this thread: http://www.excelforum.com/showthread...hreadid=375911
>
thanku Mike,
it is working perfect. I was stuck with this problem for last 3 days to get solved on so many forum's website.
finally on this forum, today only I hv registered and happy to see its solution so quickly.
thankyou once again.
Regards,
ilyaskazi
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks