MSFN Forum: Auto register HTA file? - MSFN Forum

Jump to content



  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

Auto register HTA file? Rate Topic: -----

#1 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,756
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 08 July 2005 - 06:03 PM

Ok peeps how can I make it so wpi.cmd tells windows to open wpi.hta WITH MSHTA.EXE be it reg file or command.


#2 User is offline   lionhrt 

  • Input Knowledge Here!
  • PipPip
  • Group: Members
  • Posts: 136
  • Joined: 17-February 05

Posted 08 July 2005 - 06:08 PM

Thats an answser that i would like to know myself mate, for I have trouble when i try incerting the cd into a win98 system. will not open anything , I have to manually open the hta file in order it to load.

#3 User is offline   Alanoll 

  • CODE tags people, CODE tags!
  • Group: Patrons
  • Posts: 5,496
  • Joined: 25-September 03

Posted 08 July 2005 - 06:17 PM

the simple think to do, would be to actually call the mshta.exe file rather then the HTA file directly

start "" C:\WINDOWS\system32\mshta.exe "wpi.hta"


Sort of thing...

#4 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,756
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 08 July 2005 - 06:32 PM

I can't get that to work.

This post has been edited by kelsenellenelvian: 08 July 2005 - 06:44 PM


#5 User is offline   lionhrt 

  • Input Knowledge Here!
  • PipPip
  • Group: Members
  • Posts: 136
  • Joined: 17-February 05

Posted 08 July 2005 - 06:54 PM

he is not trying to say edit the wpi.cmd to replace:

REM Start WPI and wait for its end
start /wait WPI.hta

with
REM Start WPI and wait for its end
start "" C:\WINDOWS\system32\mshta.exe "wpi.hta"


I could be way off or even set the wrong path.

but unsure if its the wpi.cmd file to edit


Remember I know nothing I'm just starting to soak in small amounts of info you are all trying to share.

This post has been edited by lionhrt: 08 July 2005 - 06:57 PM


#6 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,756
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 08 July 2005 - 07:16 PM

It kindof works mshta does start according to my taskmanager (Ihad 58 entries after trying in many different ways) but the wpi interface does not display.

This post has been edited by kelsenellenelvian: 08 July 2005 - 07:16 PM


#7 User is offline   Alanoll 

  • CODE tags people, CODE tags!
  • Group: Patrons
  • Posts: 5,496
  • Joined: 25-September 03

Posted 08 July 2005 - 07:55 PM

one moment while i download WPI...

start "" C:\WINDOWS\system32\mshta.exe "%CD%\wpi.hta"

works. MSHTA needs the full path to the wpi.hta file. %CD% is "current directory" and should work in most instances, unless calling the CMD file from another directory. If it runs via Autorun.inf, then it will be fine. Another method, though I'm not sure of how it would work is .\

This is just a work around to the registry problem, because of rights restrictions and such.

Also, C:\Windows = %systemroot% and %windir%. I don't believe %systemroot% is available on a 9x system, but %windir% should be.

#8 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,756
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 08 July 2005 - 08:21 PM

Hey that got it! Thanx

#9 User is offline   lionhrt 

  • Input Knowledge Here!
  • PipPip
  • Group: Members
  • Posts: 136
  • Joined: 17-February 05

Posted 08 July 2005 - 08:38 PM

Fantastic, nice to this resolved thanks Alanoll, good work.

may want to edit your post http://www.msfn.org/...showtopic=50304 that a solution has been found.

Not that you dont already know kelsenellenelvian to do so.


So all I would have to do is make a cmd file from this solution and place it where

#10 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,756
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 08 July 2005 - 09:05 PM

I am just adding it into wpi.cmd.

#11 User is offline   Clint 

  • Go ahead, punk'
  • PipPipPip
  • Group: Members
  • Posts: 414
  • Joined: 03-April 05

Posted 08 July 2005 - 09:24 PM

I don't know if I'm shooting blanks here, but when I remove IE and unregister it properly @ T-12, I loose .hta referers to MSHTA.EXE and as a result get a "open with" when WPI are supposed to start.

So I throw this in at the end of my massive reg to get that referer back:

[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\.hta]
@="hta_auto_file"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\hta_auto_file\shell\open\command]
@="\"C:\\WINDOWS\\system32\\mshta.exe\" \"%1\""


I thought better clutter your post a bit if there is someone out there experience
same problem. :D

#12 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,756
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 08 July 2005 - 09:26 PM

Nice to have different options.

#13 User is offline   Lost Soul 

  • Snap ... Crackle ... Pop
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 1,746
  • Joined: 12-December 03

Posted 08 July 2005 - 09:27 PM

well you definatly need ie to run a hta file so by removing ie,, id say that not a good thing

but its nice to see a work around for the prob,, nice addition to the setup cmds

This post has been edited by Lost Soul: 08 July 2005 - 09:28 PM


#14 User is offline   Clint 

  • Go ahead, punk'
  • PipPipPip
  • Group: Members
  • Posts: 414
  • Joined: 03-April 05

Posted 08 July 2005 - 09:36 PM

Lost Soul, on Jul 9 2005, 05:27 AM, said:

well you definatly need ie to run a hta file so by removing ie,, id say that not a good thing

but its nice to see a work around for the prob,, nice addition to the setup cmds
<{POST_SNAPBACK}>


No, I don't have IE...just the core ;)
..but many ppl believe you actually need IE browser...wich is not true.

This post has been edited by Clint: 08 July 2005 - 09:39 PM


#15 User is offline   lionhrt 

  • Input Knowledge Here!
  • PipPip
  • Group: Members
  • Posts: 136
  • Joined: 17-February 05

Posted 08 July 2005 - 09:39 PM

by adding it to your wpi.cmd you mean on a separate line or are you modifying the line with

REM Start WPI and wait for its end
start /wait "" C:\WINDOWS\system32\mshta.exe "%CD%\wpi.hta"

???

What no one to tell me if this is what you do. hehe

Ya I know wait your turn.

This post has been edited by lionhrt: 08 July 2005 - 11:04 PM


#16 User is offline   Alanoll 

  • CODE tags people, CODE tags!
  • Group: Patrons
  • Posts: 5,496
  • Joined: 25-September 03

Posted 08 July 2005 - 11:14 PM

i mean modifying...
i should point out, that the CMD method i put above could get tricky depending on how you call the CMD.

If you're someone who calls the CMD via CMDLINES.TXT, then the %CD% isn't the proper directory anymore, and you must know the complete path to the HTA file. If it's executed via Autorun.inf, it works fine.

I could make it more complicated to find out the drive lettering and such, but then it owuldn't work on Win9x.

I suggested the CMD trick primarily for reasons of system lockdown. If you go the registry method, the paths to the actual executable may not be right

#17 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,756
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 09 July 2005 - 02:24 AM

I will use the cmd version and add into the guide how to change for those couple of people it won't work for. You know that the masses rule and more probs should be solved then made.

#18 User is offline   lionhrt 

  • Input Knowledge Here!
  • PipPip
  • Group: Members
  • Posts: 136
  • Joined: 17-February 05

Posted 09 July 2005 - 07:17 PM

Well I'm just using at the moment WPI to install games and programs. It is not integrated into an Unattended XP cd

so basically all I have in my root are the files that are stored in the main wpi download. modified useroptions.js and config.js and folder representing all my reg files/graphic thumbs for the descript box and install folder when I stored all my exe files, but other then that nothing else has been changed.

So i guess if autorun is enabled as with my xp box then it calls the autorun.inf which calls the wpi.cmd and loads the wpi.hta.


I run everything off the dvd which i dont believe is setup to copy everything onto HD first then install.

So what would be my step to create a file that will load wpi on a win98 machine that is not autorun enabled. and would I place that file whether it be a cmd gile into the root of the cd and would I have to change the autorun.inf to load this file instead of the wpi.cmd.

Thanks for everything.

I know its a lot but the whole process is to learn and to teach. Hope one day I can be here to teach.

lionhrt

#19 User is offline   Kelsenellenelvian 

  • WPI Guru
  • Group: Developers
  • Posts: 7,756
  • Joined: 18-September 03
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 09 July 2005 - 07:24 PM

If autorun is not enabled there is nothing that can be done windows will not even read the CD untill you navigate to it.

#20 User is offline   lionhrt 

  • Input Knowledge Here!
  • PipPip
  • Group: Members
  • Posts: 136
  • Joined: 17-February 05

Posted 09 July 2005 - 07:49 PM

I should have known that , so if you have win 98 autorun enabled and find it still doesnt load wpi.hta (is basically what we are trying to figure out here. I have read the replies yet still dont understand how it can be done.

Share this topic:


  • 2 Pages +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy