Hyperlink to Explorer

A

alex

Hyperlink to Explorer

Hello all,

Using Access ’03…

I’m wondering if anyone has some experience with hyperlinks (in an
Access form) opening folders in Windows Explorer.

My hyperlinks work, but when Windows Explorer opens, it includes the
‘Folders’ pane. I would like it to open with only one pane (less
confusing for the user).

I thought maybe something could be appended to the address which would
control how Explorer is opened…

I may need to post this in another group, but since the hyperlinks are
in Access and this is a very knowledge group, I thought I’d start
here.

Thanks,
alex
 
J

James A. Fortune

Hyperlink to Explorer

Hello all,

Using Access ’03…

I’m wondering if anyone has some experience with hyperlinks (in an
Access form) opening folders in Windows Explorer.

My hyperlinks work, but when Windows Explorer opens, it includes the
‘Folders’ pane. I would like it to open with only one pane (less
confusing for the user).

I thought maybe something could be appended to the address which would
control how Explorer is opened…

I may need to post this in another group, but since the hyperlinks are
in Access and this is a very knowledge group, I thought I’d start
here.

Thanks,
alex

You might get a hint from:

http://www.microsoft.com/windowsxp/using/setup/learnmore/tips/bertleff1.mspx

James A. Fortune
(e-mail address removed)
 
T

Tom Wickerath

Hi Alex,

If you are willing to use VBA code, I think this will work for you:

Dim varReturn As Variant
Dim strPath As String

strPath = "Your desired path goes here" (perhaps CurrentProject.Path)

varReturn = Shell("Explorer " & strPath, vbNormalFocus)



Tom Wickerath
Microsoft Access MVP
http://www.accessmvp.com/TWickerath/
__________________________________________
 
A

alex

Hi Alex,

If you are willing to use VBA code, I think this will work for you:

Dim varReturn As Variant
Dim strPath As String

strPath = "Your desired path goes here" (perhaps CurrentProject.Path)

varReturn = Shell("Explorer " & strPath, vbNormalFocus)

Tom Wickerath
Microsoft Access MVPhttp://www.accessmvp.com/TWickerath/
__________________________________________












- Show quoted text -

Thanks Tom,
That's exactly what I did in VBA. What's interesting, is that if the
hyperlink is executed, WE opens with the folder's pane. If you
convert the memo field to text and strip the "#" around the string,
place it in the shell function, it opens WE without the folder's
pane.

What's also strange is that my users create hyperlinks in the same
way, but they come out different (are recorded differently)...like so:
#Q:\my folder#
or
Q:\my folder#Q:\my folder#

It made stripping the "#" a little tricky, but possible.

Thanks for the help,
alex
 
T

Tom Wickerath

Hi Alex,

I don't even use the Hyperlink data type any more these days. Instead, I
store the path in a text field. I use the maximum field size of 255, which is
usually always sufficient (one can run a function to convert file and folder
names to the shortened "DOS-like" form). Then use this in code:

Application.FollowHyperlink [FieldName]


Tom Wickerath
Microsoft Access MVP
http://www.accessmvp.com/TWickerath/
__________________________________________
 

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