Displaying a web browser based on data - how?

R

Rick Brandt

Nozza said:
I want to be able to launch a browser (Internet explorer), and use a
postcode displayed on a form to open a webpage to show where the
location is.

So, if someone's postcode is SW1A 2AB (eg Downling Street, London)
then the URL launched will be

http://www.multimap.com/map/browse...._result=&db=pc&lang=&keepicon=true&pc=SW1A2AB

I can easily strip out the spaces, but I want to know how to launch IE
when a button is pressed.

Many thanks

Noz

Application.FollowHyperlink "URL"
 
R

Rick Brandt

Nozza said:
... but only if I hard code the URL!

If I use

Application.FollowHyperlink
"http://www.multimap.com/map/browse.cgi?client=public&search_result=&db=pc&lang=&keepicon=true&pc="
& me.Text2.Text

I get the error message

"You can't reference a property or method for a control unless the
control has focus"

Nearly there... but not!

Thanks

Noz

Get rid of .Text

That would be the correct syntax in VB, but not in Access. In Access the
Value property is what you want and since that is the defrault property you
don't need to explicitly reference it. The Text property is for referencing
the changed value in a control as you are typing but before the control is
updated. For that reason it is only available when the control has focus.
 
N

Nozza

Get rid of .Text

That would be the correct syntax in VB, but not in Access. In Access the
Value property is what you want and since that is the defrault property you
don't need to explicitly reference it. The Text property is for referencing
the changed value in a control as you are typing but before the control is
updated. For that reason it is only available when the control has focus.

Awesome.

Works a treat :) Can now view a map of where all clients are :)

Thanks

Noz
 

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

Similar Threads


Top