MSFN Forum: generate.js, problem with detected path - MSFN Forum

Jump to content



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

generate.js, problem with detected path Z:\\ not Z: ?! Rate Topic: -----

#1 User is offline   Sonic 

  • Sonic
  • Group: Patrons
  • Posts: 1,595
  • Joined: 04-December 03

Posted 13 December 2005 - 12:58 PM

delete me, finally I have rewriten generate.js to my objectifs ...

This post has been edited by sonic: 13 December 2005 - 02:40 PM



#2 User is offline   glent 

  • Tpyo Spceialist
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,041
  • Joined: 16-August 04

Posted 14 December 2005 - 04:17 PM

care to post what you changed and what it does?

#3 User is online   Kelsenellenelvian 

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

Posted 14 December 2005 - 04:22 PM

Yeah I would like to see what you did to.

#4 User is offline   Sonic 

  • Sonic
  • Group: Patrons
  • Posts: 1,595
  • Joined: 04-December 03

Posted 14 December 2005 - 05:16 PM

In fact, generate.js generates path %cdrom% as correct path with it runs from a local folder, but when it runs on network (I mapp to a Z: drive) the path generated becomes Z:\\Folder\MySetup.msi /qb so RunonceEx works because it can read after \\ ... but when I have regedit /s z:\\regfile.reg , regedit can't handle \\ and error .... so I have removed one \ from my config.js but after when I run from local folder path become Z:Folder\MySetup.msi /qb ........ and finally I'm boring to find the good solution so I'm thinking about other way ...

So, finally I have "tuned" generate.js adding new two variables (because during my finding solution I have thinking about other possibility ^^)
%apps% and %logs% ... this two paths are define in cmd environnement by my batchfile (edit: I prefer CMD environnement to find path & co ) (which it test folder if exist, network more or not & more ...) and generate.js replace path ...
function replpath(u) {  
//
	softs = WshEnv("sapps"); //sapps set in batch like "set sapps="...."
	logs = WshEnv("slogs"); //slogs set in batch like "set slogs="...."
//
  rs = rs.replace(/%softs%/gi, softs);
  rs = rs.replace(/%logs%/gi, logs);


I have posted too fast :( so you can delete me ^^

Goodbye & big great job to all contributors of wpi, I "tune" this all the day and it will be perfect soon !

This post has been edited by sonic: 14 December 2005 - 05:18 PM


#5 User is offline   Sonic 

  • Sonic
  • Group: Patrons
  • Posts: 1,595
  • Joined: 04-December 03

Posted 21 December 2005 - 06:09 PM

I'M BAD VERY BAD !!!

During the discovering of WPI (few months ago ...) I have edited my configs.js & useroptions.js ... and I have set discpath='root' ! why? I don't remember ... so I have many error with \\ & co. ....
I have all recorrect my wpi and now works great , configs too .. I'm happy ^^ ... Now to get perfect, is it possible to search WPI.ico in parrent directory ? (I have tried but errors ...)

Thanks. goodbye.

This post has been edited by sonic: 21 December 2005 - 06:16 PM


Share this topic:


Page 1 of 1
  • 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