![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | HTML webpage within IE loagin HTA with agruments Hello, I have found you can actualy execute an HTA with some commandline with the commandLine attribute. I was wondering if it was possible to lauch an HTA with some arguments from a web page within IE. That would be the command to open the HTA <A HREF="query\QueryViewer.hta">580</A> This actualy work and open the HTA, but it would be really cool if I could pass arguments |
My System Specs![]() |
| | #2 (permalink) |
| | Re: HTML webpage within IE loagin HTA with agruments <A HREF="query\QueryViewer.hta?blah=580">580</A> Just parse out the arguments from the href within the hta. Tim <malo.lexandre@xxxxxx> wrote in message news:0b7acb90-9397-4d4c-82c8-4d25fc5112cb@xxxxxx Quote: > Hello, > > I have found you can actualy execute an HTA with some commandline > with the commandLine attribute. > I was wondering if it was possible to lauch an HTA with some arguments > from a web page within IE. > > That would be the command to open the HTA > <A HREF="query\QueryViewer.hta">580</A> > > This actualy work and open the HTA, but it would be really cool if I > could pass arguments |
My System Specs![]() |
| | #3 (permalink) |
| | Re: HTML webpage within IE loagin HTA with agruments As far as I can recall you can't do this. However you may be able to use the Shell.Application.Windows method to get a reference back to the instance of IE that launched it. -- Joe Fawcett (MVP - XML) http://joe.fawcett.name "Tim Williams" <timjwilliams@xxxxxx> wrote in message news:utE4Rl30JHA.6004@xxxxxx Quote: > <A HREF="query\QueryViewer.hta?blah=580">580</A> > > Just parse out the arguments from the href within the hta. > > Tim > > <malo.lexandre@xxxxxx> wrote in message > news:0b7acb90-9397-4d4c-82c8-4d25fc5112cb@xxxxxx Quote: >> Hello, >> >> I have found you can actualy execute an HTA with some commandline >> with the commandLine attribute. >> I was wondering if it was possible to lauch an HTA with some arguments >> from a web page within IE. >> >> That would be the command to open the HTA >> <A HREF="query\QueryViewer.hta">580</A> >> >> This actualy work and open the HTA, but it would be really cool if I >> could pass arguments > |
My System Specs![]() |
| | #4 (permalink) |
| | Re: HTML webpage within IE loagin HTA with agruments Here's an example: I'm using the HTA just as a host for a page within an iframe, so I'm passing the querystring parameter along to that page. The hosted page gets the HTA privs. Tim '************************************** <html> <head> <title>Edit Associations</title> <hta:application icon="images/folder.ico" id="Tracker" applicationName="Tracker" singleInstance="yes" showInTaskbar="yes" borderStyle="normal" maximizebutton="no" SYSMENU="yes" selection="yes" /> <script type="text/javascript"> function Init() { var qs = window.location.search.substring(1) + ""; if(qs.length>0) { //pass the querystring through to the iframe page document.getElementById("frmEdit").src = "edit.asp?" + qs; window.resizeTo(800, 750); }else{ alert("No Id was passed!"); window.close(); } } </script> </head> <body scroll="no" style="margin:0px" onload="Init();"> <iframe id="frmEdit" width="100%" height="100%" frameborder="no" border="0" marginheight="0" marginwidth="0" application="yes" src="blank.html"> </iframe> </body> </html> '**************************************** "Joe Fawcett" <joefawcett@xxxxxx> wrote in message news:eOd7oR80JHA.2656@xxxxxx Quote: > As far as I can recall you can't do this. However you may be able to use > the Shell.Application.Windows method to get a reference back to the > instance of IE that launched it. > > -- > > Joe Fawcett (MVP - XML) > > http://joe.fawcett.name > > "Tim Williams" <timjwilliams@xxxxxx> wrote in message > news:utE4Rl30JHA.6004@xxxxxx Quote: >> <A HREF="query\QueryViewer.hta?blah=580">580</A> >> >> Just parse out the arguments from the href within the hta. >> >> Tim >> >> <malo.lexandre@xxxxxx> wrote in message >> news:0b7acb90-9397-4d4c-82c8-4d25fc5112cb@xxxxxx Quote: >>> Hello, >>> >>> I have found you can actualy execute an HTA with some commandline >>> with the commandLine attribute. >>> I was wondering if it was possible to lauch an HTA with some arguments >>> from a web page within IE. >>> >>> That would be the command to open the HTA >>> <A HREF="query\QueryViewer.hta">580</A> >>> >>> This actualy work and open the HTA, but it would be really cool if I >>> could pass arguments >> > |
My System Specs![]() |
| | #5 (permalink) |
| | Re: HTML webpage within IE loagin HTA with agruments Yes, but that's hosting HTML page within an HTA. The poster asked about launching an HTA from within an HTML page and passing querystring parameters. -- Joe Fawcett (MVP - XML) http://joe.fawcett.name "Tim Williams" <timjwilliams@xxxxxx> wrote in message news:OddcZ7D1JHA.3988@xxxxxx Quote: > Here's an example: I'm using the HTA just as a host for a page within an > iframe, so I'm passing the > querystring parameter along to that page. The hosted page gets the HTA > privs. > > Tim > > '************************************** > <html> > <head> > <title>Edit Associations</title> > > <hta:application icon="images/folder.ico" > id="Tracker" > applicationName="Tracker" > singleInstance="yes" > showInTaskbar="yes" > borderStyle="normal" > maximizebutton="no" > SYSMENU="yes" > selection="yes" > /> > > <script type="text/javascript"> > function Init() > { > var qs = window.location.search.substring(1) + ""; > > if(qs.length>0) > { > //pass the querystring through to the iframe page > document.getElementById("frmEdit").src = "edit.asp?" + qs; > window.resizeTo(800, 750); > }else{ > alert("No Id was passed!"); > window.close(); > } > > } > </script> > > </head> > > <body scroll="no" style="margin:0px" onload="Init();"> > <iframe id="frmEdit" width="100%" height="100%" > frameborder="no" border="0" > marginheight="0" marginwidth="0" > application="yes" > src="blank.html"> > </iframe> > </body> > </html> > '**************************************** > > > "Joe Fawcett" <joefawcett@xxxxxx> wrote in message > news:eOd7oR80JHA.2656@xxxxxx Quote: >> As far as I can recall you can't do this. However you may be able to use >> the Shell.Application.Windows method to get a reference back to the >> instance of IE that launched it. >> >> -- >> >> Joe Fawcett (MVP - XML) >> >> http://joe.fawcett.name >> >> "Tim Williams" <timjwilliams@xxxxxx> wrote in message >> news:utE4Rl30JHA.6004@xxxxxx Quote: >>> <A HREF="query\QueryViewer.hta?blah=580">580</A> >>> >>> Just parse out the arguments from the href within the hta. >>> >>> Tim >>> >>> <malo.lexandre@xxxxxx> wrote in message >>> news:0b7acb90-9397-4d4c-82c8-4d25fc5112cb@xxxxxx >>>> Hello, >>>> >>>> I have found you can actualy execute an HTA with some commandline >>>> with the commandLine attribute. >>>> I was wondering if it was possible to lauch an HTA with some arguments >>>> from a web page within IE. >>>> >>>> That would be the command to open the HTA >>>> <A HREF="query\QueryViewer.hta">580</A> >>>> >>>> This actualy work and open the HTA, but it would be really cool if I >>>> could pass arguments >>> >>> >> > |
My System Specs![]() |
| | #6 (permalink) |
| | Re: HTML webpage within IE loagin HTA with agruments Joe, I just posted an example I had on hand. There's no requirement for the HTA to contain a hosted iframe - it's just as easy to do this: var qs = window.location.search.substring(1) + ""; alert("Passed parameter: " + qs); //or do something more interesting with it... After all, an HTA is really just mostly a regular HTML page: it just runs in a different environment. Tim On May 14, 9:43*am, "Joe Fawcett" <joefawc...@xxxxxx> wrote: Quote: > Yes, but that's hosting HTML page within an HTA. The poster asked about > launching an HTA from within an HTML page and passing querystring > parameters. > > -- > > Joe Fawcett (MVP - XML)http://joe.fawcett.name"Tim Williams" <timjwilli....@xxxxxx> wrote in message > > news:OddcZ7D1JHA.3988@xxxxxx > > > Quote: > > Here's an example: I'm using the HTA just as a *host for a page within an > > iframe, so I'm passing the > > querystring parameter along to that page. *The hosted page gets the HTA > > privs. Quote: > > Tim Quote: > > '************************************** > > <html> > > <head> > > *<title>Edit Associations</title> Quote: > > *<hta:application *icon="images/folder.ico" > > * * * id="Tracker" > > * * * applicationName="Tracker" > > * * * singleInstance="yes" > > * * * showInTaskbar="yes" > > * * * borderStyle="normal" > > * * * maximizebutton="no" > > * * * SYSMENU="yes" > > * * * selection="yes" > > * * * * */> Quote: > > *<script type="text/javascript"> > > * function Init() > > * { > > * *var qs = window.location.search.substring(1) + ""; Quote: > > * *if(qs.length>0) > > * *{ > > * * //pass the querystring through to the iframe page > > * * document.getElementById("frmEdit").src = "edit.asp?" + qs; > > * * window.resizeTo(800, 750); > > * *}else{ > > * * alert("No Id was passed!"); > > * * window.close(); > > * *} Quote: > > * } > > *</script> Quote: > > </head> Quote: > > <body scroll="no" style="margin:0px" onload="Init();"> > > *<iframe id="frmEdit" width="100%" height="100%" > > * frameborder="no" border="0" > > * marginheight="0" marginwidth="0" > > * application="yes" > > * src="blank.html"> > > *</iframe> > > </body> > > </html> > > '**************************************** Quote: > > "Joe Fawcett" <joefawc...@xxxxxx> wrote in message > >news:eOd7oR80JHA.2656@xxxxxx Quote: > >> As far as I can recall you can't do this. However you may be able to use > >> the Shell.Application.Windows method to get a reference back to the > >> instance of IE that launched it. Quote: Quote: > >> -- Quote: Quote: > >> Joe Fawcett (MVP - XML) Quote: Quote: Quote: Quote: > >> "Tim Williams" <timjwilli...@xxxxxx> wrote in message > >>news:utE4Rl30JHA.6004@xxxxxx > >>> <A HREF="query\QueryViewer.hta?blah=580">580</A> Quote: Quote: > >>> Just parse out the arguments from the href within the hta. Quote: Quote: > >>> Tim Quote: Quote: > >>> <malo.lexan...@xxxxxx> wrote in message > >>>news:0b7acb90-9397-4d4c-82c8-4d25fc5112cb@xxxxxx > >>>> Hello, Quote: Quote: > >>>> I have found you can actualy execute an HTA with some commandline > >>>> with the commandLine attribute. > >>>> I was wondering if it was possible to lauch an HTA with some arguments > >>>> from a web page within IE. Quote: Quote: > >>>> That would be the command to open the HTA > >>>> <A HREF="query\QueryViewer.hta">580</A> Quote: Quote: > >>>> This actualy work and open the HTA, but it would be really cool if I > >>>> could pass arguments- Hide quoted text - > - Show quoted text - |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| dns error on one particular webpage | Network & Sharing | |||
| working on html objects using HTML DOM, VBscript | VB Script | |||
| cant print from webpage | Vista print fax & scan | |||
| Webpage as Backgournd | Vista General | |||
| Webpage will not display | Vista General | |||