How to open a URL from MS Access with parameters

后端 未结 2 828
情话喂你
情话喂你 2020-12-16 17:54

I have a basic MS Access application that has a button on a form that should open a webpage with the ID of the Access record as the parameter, but everything I have tried re

相关标签:
2条回答
  • 2020-12-16 18:24

    Application.FollowHyperlink is fickle.

    Use either ShellExecute:
    Open an html page in default browser with VBA?

    or

    CreateObject("Shell.Application").Open "http://example.com/index.php?r=controller/action&id=" & Me.ID 
    

    see https://stackoverflow.com/a/18922262/3820271

    0 讨论(0)
  • 2020-12-16 18:34

    Note that if you are having issues with CreateObject("Shell.Application").Open not working with a variable, it might be a casting issue - try tossing a CVar() around the parameter. See https://stackoverflow.com/a/56173911/8512931 for more details.

    0 讨论(0)
提交回复
热议问题