Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Build a URL from the info. on a form, can you help

Status
Not open for further replies.

MHadden

Programmer
May 13, 2001
105
0
0
I want to send the current info from an Access 2k form to an internet address. The following attempt didn't work. Can anyone advise, or at least let me know if I'm heading in the right direction.

Private Sub CmdMap_Click()
Dim strURL As String
Dim dblHandle As Double, strCommand As String
a = [Address]
c = [City]
s = [StateOrProvince]
p = [PostalCode]
i = "United States"

'build URL from address
strURL = " & _
"&outlmap.htm?a&c&s&p&HELPLCID=1033"

'create command string (e.g., Start, Run... string)
strCommand = "c:\program files\internet explorer\iexplore.exe " & strURL
'start a new browser window and load it!
dblHandle = Shell(strCommand, vbNormalFocus)

End Sub MichaelHadden@BigFoot.Com
If you give someone a fish, you have given them a meal. If you teach someone to fish, you have given them MANY meals!
 
You have to make use of references, in this case the
Microsoft Internet Controls REFERENCE. Once that has been
done its a matter of declaring the correct objects.


Sub ShowTekTips()

Dim IE As InternetExplorer

Set IE = New InternetExplorer
IE.Visible = True
IE.Navigate "Set IE = Nothing

End Sub


Good luck!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top