Page 1 of 1

Call default browser

PostPosted: Tue Aug 01, 2006 12:52 pm
by joshhuggins
I was going to post some of my toolbar button codes that are links to useful field related websites (UL search, ICC-ES search etc.), but then I realized that a lot of our users use Firefox, where as my codes all point to IE. So that got me googling for a way to call the users default browser so I could use the P= code, but I couldn't find a way to do it that works with the P= code. Anyone else have any ideas?
(post moved by Josh)

PostPosted: Tue Aug 01, 2006 1:12 pm
by Brian Engebretson
That’s very generous Josh. I’m a Firefox user, but I’m not opposed to using IE on occasion. I would say just post what you have and it’s up to the rest of us to make it work for our individual preferences.

PostPosted: Tue Aug 01, 2006 1:52 pm
by devinder
I don't know what your syntax is, but the following works

Code: Select all[Web1]
Icon=
Hint=DataCAD Homepage
P=rundll32 url.dll,FileProtocolHandler www.datacad.com


PostPosted: Tue Aug 01, 2006 2:02 pm
by joshhuggins
Ah, that works Devinder. I found something like that on the net, but it was missing the ",FileProtocolHandler" and was not working. Kwel, Thanks :!:

PostPosted: Wed Jan 10, 2007 7:16 pm
by joshhuggins
Is there a similar way to have PDF files open with the associated program? I've tried several functions from shell32.dll & kernel32.dll but haven't found one that works yet.
Code: Select allP00=rundll32 shell32.dll,ShellExecute C:\My Documents\Datacad\Help\Simpson.pdf
I thought this should work, but it doesn't. I'd really like to be able to add the switch /A page=4 too but don't know if it's possible when launching this way. Can anyone point a noob in the right direction please? Thanks.

PostPosted: Thu Jan 11, 2007 9:58 am
by devinder
try this.
Code: Select allrundll32 SHELL32.DLL,ShellExec_RunDLL "C:\My Documents\Datacad\Help\Simpson.pdf"

Re: Call default browser

PostPosted: Thu Mar 10, 2011 5:33 pm
by joshhuggins
I returned to trying to get this part of a toolbar code working today. Is there anyway to pass on app specific switches/parameters using
Code: Select all=rundll32 SHELL32.DLL,ShellExec_RunDLL "file.exe"
I am trying to get a PDF to open to a specific page using Adobe's parameters /A page=4 per Adobe's Open Parameters doc examples on Page 5 I've tried multiple versions of stringing the parameter into the code, but the closest is getting the doc to just open. I've also tried using a local URL path via a web browser with Adobe's URL examples on page 7 but I can't seem to get that to work either.
Code: Select all=rundll32 SHELL32.DLL,ShellExec_RunDLL "file:///C:/Datacad/Help/Building%20Products/Simpson.pdf"
Any help would be appreciated.