New VBA problem - Excel 2004 / OS 10.3.8

M

msxlsgg

One of my programs that has worked fine before just suddenly stopped
working on two different Macs with Office 2004 and OS 10.3.8 -
something in a recent Apple auto software update maybe?

Try this code:

Sub test()

sFileToOpen = Application.GetOpenFilename
If sFileToOpen <> False Then
MsgBox "Open " & sFileToOpen
End If


End Sub

In every case I've tried, the path to the file to open is wrong -
sometimes it leaves out the next-to-last folder, sometimes it leaves
out the whole path, returning just Harddrive:filename without any of
the folders inbetween.. didn't used to work like this!

Any suggestions?

thanks
Lee
 
B

Bernard Rey

One of my programs that has worked fine before just suddenly stopped
working on two different Macs with Office 2004 and OS 10.3.8 -
something in a recent Apple auto software update maybe?
..../...

In every case I've tried, the path to the file to open is wrong -
sometimes it leaves out the next-to-last folder, sometimes it leaves
out the whole path, returning just Harddrive:filename without any of
the folders inbetween.. didn't used to work like this!

I suppose this is the good old list view trick: in the GetOpenFilename
dialog, set it to "columns view" or, if you stick to list view, make sure to
"open" the folder with double-clicks. If you just toggle the little
triangles in front of the folders, that part of the path will be ignored,
and it's the folder whose name is displayed in the drop down menu that will
be taken as the last folder name in the path.
 
M

msxlsgg

Bernard: Vous êtes un génie! Merci beaucoup - c'était le problème.
Salutations vers Toulouse - j'ai été là plusieurs fois de travailler
avec CNES; c'est une ville très gentille!

Thanks for the help! That was the problem. I will amend the
instructions to user accordingly!

regards,
lee
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top