Mark, just when I received your suggestion I was typing a reply asking if
the OLEobject class could be of use in this? I will study your response to
see how much I understand ;)
Thanks.

Staffan



On Wed, Dec 12, 2012 at 5:38 PM, Mark Miesfeld <miesf...@gmail.com> wrote:

> On Wed, Dec 12, 2012 at 8:24 AM, Mark Miesfeld <miesf...@gmail.com> wrote:
> > On Wed, Dec 12, 2012 at 7:59 AM, Staffan Tylen <staffan.ty...@gmail.com>
> wrote:
> >
> >> OK thanks, but if I make life a bit more complex by saying that the file
> >> name is abc.def and it should be opened in the default browser, how
> could
> >> that be done when 'def' is not a known extension?
> >
> > You could only do it if you, the programmer, know what the default
> > browser is.
>
> You could of course write code to figure it out.
>
> C:\work.ooRexx\wc\ooDialog\trunk>assoc | grep html
> .cshtml=VisualStudio.cshtml.10.0
> .dochtml=wordhtmlfile
> .docmhtml=wordmhtmlfile
> .dothtml=wordhtmltemplate
> .htm=htmlfile
> .html=htmlfile
> .mdbhtml=accesshtmlfile
> .mht=mhtmlfile
> .mhtml=mhtmlfile
> .pothtml=powerpointhtmltemplate
> .ppthtml=powerpointhtmlfile
> .pptmhtml=powerpointmhtmlfile
> .pubhtml=publisherhtmlfile
> .pubmhtml=publishermhtmlfile
> .vbhtml=VisualStudio.vbhtml.10.0
> .wizhtml=accessthmltemplate
> .xht=xhtmlfile
> .xhtml=xhtmlfile
> .xlshtml=Excelhtmlfile
> .xlsmhtml=excelmhtmlfile
> .xlthtml=Excelhtmltemplate
>
> C:\work.ooRexx\wc\ooDialog\trunk>ftype | grep -wi htmlfile
> htmlfile="C:\Program Files (x86)\Internet Explorer\iexplore.exe" -nohome
>
> So, it looks like the string:
>
> '"C:\Program Files (x86)\Internet Explorer\iexplore.exe" -nohome
> myFile.def'
>
> passed to the outside environment would work.
>
> On Windows there are some other classes, like the WindowsRegistry
> class or the oleObject class that might be of use.
>
> You would need to research if the OS stores the information in the
> registry.  If so, you could use the WindowsRegistry class to retrieve.
>
> Or, if the information is available through WMI, you could use the
> oleObject to retrieve it.
>
> The brute force method above may be good enough.
>
> --
> Mark Miesfeld
>
>
> ------------------------------------------------------------------------------
> LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial
> Remotely access PCs and mobile devices and provide instant support
> Improve your efficiency, and focus on delivering more value-add services
> Discover what IT Professionals Know. Rescue delivers
> http://p.sf.net/sfu/logmein_12329d2d
> _______________________________________________
> Oorexx-users mailing list
> Oorexx-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/oorexx-users
>
------------------------------------------------------------------------------
LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial
Remotely access PCs and mobile devices and provide instant support
Improve your efficiency, and focus on delivering more value-add services
Discover what IT Professionals Know. Rescue delivers
http://p.sf.net/sfu/logmein_12329d2d
_______________________________________________
Oorexx-users mailing list
Oorexx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-users

Reply via email to