Files launched w/ FollowHyperlink open but not visible

  • Thread starter Thread starter Ruben
  • Start date Start date
R

Ruben

Hello,

I am using the "Application.FollowHyperlink strFilePath, , True" line
of code from within access forms to launch any file type I want
(e.g.,
xls, doc, pdf, etc.). The files open up okay, but open up in the
background. How do I make them open up on top where they are
visible?
I have tried various things like "Appliction.Visible=True / False"
and "Screen.ActiveControl.Visible=True / False" but have not been
able
to figure it out.


Anyone's help with this would be very much appreciated.


Regards,


Ruben Munoz
 
In general this should not be the case. In all my databases the file that
opens takes the focus except in one instance; I have experienced problems
with PDFs but this gets solved by having Acrobat updated (they fixed whatever
the isssue was).

Furthermore, you do not mention what version of access you are using, nor
the type of documents you are experiencing this problem with (all files types
have this behavior?), nor do you give us you complete code routine to look
over. Perhaps your code has other elements that take back the focus after
you make the FollowHyperlink call... Just a thought. Give us some more info
and we can try to help you more.
--
Hope this helps,

Daniel Pineault
http://www.cardaconsultants.com/
For Access Tips and Examples: http://www.devhut.com/index.php
Please rate this post using the vote buttons if it was helpful.
 
In general this should not be the case.  In all my databases the file that
opens takes the focus except in one instance; I have experienced problems
with PDFs but this gets solved by having Acrobat updated (they fixed whatever
the isssue was).

Furthermore, you do not mention what version of access you are using, nor
the type of documents you are experiencing this problem with (all files types
have this behavior?), nor do you give us you complete code routine to look
over.  Perhaps your code has other elements that take back the focus after
you make the FollowHyperlink call...  Just a thought.  Give us some more info
and we can try to help you more.
--
Hope this helps,

Daniel Pineaulthttp://www.cardaconsultants.com/
For Access Tips and Examples:http://www.devhut.com/index.php
Please rate this post using the vote buttons if it was helpful.







- Show quoted text -

Daniel,

Thanks for setting me straight on the cross postings. It is my first
time posting.

I am using Access 2000. What this part of my application does is that
it enables users to double-click on a hyperlink text field within a
form in order to "attach" external documents such as xls, doc, pdf,
etc., to the form. This launches the Open File Dialog from which they
can select the file they want to "attach". Once a selection has been
made, the file path to their document is captured to that text field
as a hyperlink that launches their file or document the next time a
user clicks on it.

Although the Shell command does seem to do the trick, I can't figure
out how to make it work within my application.
Unless there's a way to assign the "attached" file path within the
Shell command to a string or variable, I don't know if the Shell
command could be made to work in this case.

The only line of code I have behind the OnClick event of the hyperlink
text field is:

"Application.FollowHyperlink strFilePath, , True"

It works fine to the extent of opening up an external file or
application, they just don't open up on top. That goes for any file
type that is launched.

-Ruben
 
Back
Top