Jump to content

Fredledingue

Member
  • Posts

    1,274
  • Joined

  • Last visited

  • Donations

    0.00 USD 
  • Country

    Lithuania

Everything posted by Fredledingue

  1. Why the one "or" the other? Why not the one "and" the other?. I have a pen, and Windows 98, and Windows XP, and a car, and a bed, and a WC, and I love them all. Well, I'll confess you all my hidden secret: I try to keep attentive to use each of these things for its own finality... I have a pen attached with a thread to my monitor screen. It's by far the most secure tool to take notes I need when I'm going away from the computer, no matter the OS. It's much easier than typing them in notepad (some woul even use Word) copy the file to a usb stick, find another computer when to insert the usb stick, find the file on the usb stick etc etc. I have access to paper even during ower outage or HDD failure or something. I also don't need to wait one minute (two with vista) before starting to look for a document. Pens are more productive than you think. It only depends on what you are writing for. Finaly notes on paper are an absolute necessity to reinstall any windows OS properly.
  2. The reason why I'm still using w98se today is the huge security black hole caused by XP during 6 years. It's possible to increaseXP security by setting up limited account but it's always a nightmare to cope with the access denied errors. Vista is slightly better than XP, but such bloatware. Only w7 is an OS I contemplate using, if M$ promises on it are true.
  3. There are very little CSS and even less Javascript code that woudln't work on IE6. Saying that a website won't work is an overstatement. Perhaps it won't display perfectly but you still get the content.
  4. Great! I didn't know it was pssible. I seldom use the same functions from one script to another but it's useful to know. What does this mean: window.onbeforeunload=preUnload; ?
  5. Scr1ptW1zard, I don't know if you can add a second script in vbscript inside the hta if you do that.
  6. I haven't been logged out today! Looks like it's fixed. Thanks!
  7. Ok, I'm leaving for holliday now, I'll try to check in here from time to time. Regards.
  8. Just one question, sir: Which software do you suggest to use while testing? "Bitmap" sounds like graphic softwares should run during the test, isn't it?
  9. Me too. At the moment, I'm systematicaly logged off after 4 or 5 minutes.
  10. Yes, of course. Instead of a loop you can type: Execute ObjFile.ReadAll Be careful to respect vbs syntax in the text file.
  11. No, no, "temp.vbs" is an example and it represents your vbscript file. The code to capture the parameter in hta is the following: Here "testcmdl" is also an example, you can name the way you want, just without white space. "testcmdl.commandLine" will return the entire command line used to launch the hta (including the param), so you will have to crop the text from the command line that you need. <HEAD> <HTA:APPLICATION ID="testcmdl"> <script LANGUAGE="VBScript"> Sub window_onLoad() MyParam = testcmdl.commandLine End Sub </SCRIPT> </HEAD>
  12. objshell.run("1"),0 '<--- Huh? **** Ok I understand now. Running "1" looked a little bit wierd but it can be valid if 1.exe is registered. Note that you shouldn't put parenthesis when the command doesn't return a variable. objshell.run "1.exe" ,0 but you must type errOut = objshell.run("1.exe"),0 Note that errOut is not the same as stdOut. If this code is so simple, you can include it in VbScript. 'Program to workaround GImageX getting System Error 1231 objShell.Run "%comspec% /c net use z: \\imagex.wds.local\images Password1 /user:remote", 0, True objShell.Run "%comspec% /c net use v: \\vistaserver.wds.local\share Password1 /user:remote", 0, True Sleep 1000 objShell.Run "mshta x:\windows\system32\ImageX.hta" window.close So add the button in the hta form.
  13. Sent params simply: WshShell.Run "temp.vbs Text1 Text2 Text3", 1, True Params containing white spaces WshShell.Run "temp.vbs ""Mon Text 1"" ""Mon Text 2"" ""Mon Text 3""", 1, True Named params: WshShell.Run "temp.vbs /paramA:Text1 /paramB:Text2 /paramC:Text3", 1, True Collect parameters aka arguments: If only one: Arg = WScript.Arguments(0) If sevral: Set Args = Wscript.Arguments For Each a in Args Arg=a Next Taking named arguments Set NamedArgs = Wscript.Arguments.Named A = NamedArgs("ParamA") B = NamedArgs("ParamB") C = NamedArgs("ParamC") Taking named and unamed arguments: Set NamedArgs = Wscript.Arguments.Named Set UnNamedArgs = Wscript.Arguments.Unnamed A = NamedArgs("ParamA") B = NamedArgs("ParamB") C = NamedArgs("ParamC") MyVar0 = UnNamedArgs(0) MyVar1 = UnNamedArgs(1) MyVar2 = UnNamedArgs(2)
  14. Hi, There were so many inconsistencies that I couldn't let this script like that so I spent some time cleaning it up. I found indeed an obvious mistake in the EnumDirs sub. Re-download the zip file and try. There are 4 files. All 4 files must be in the same directory. This avoid rewriting hta and vbs again and again. And it frees up many many lines of code in the main hta. The replaced the sub parseFile by the one we worked on on this thread. The original sub has been renamed parseFileOri and is disabled. On line 657 and 362 (of my version) there is "VARIABLE DOESN'T EXIST ELSEWHERE", it means that you should fix it. (I didn't know what to do.) HTH
  15. I have looked at the full source code. If you want I can correct and clean up redundancies and other stuffs. I already replaced all the "& Chr(34) &" by "".... My version here: http://www.hageart.com/vbs/ImageX.zip Edit: There is a problem with this script: It writes a hta file with only one variable different in the whole hta script (CMDpartHD). It would be better to: 1/ create the script of this hta in 2 separate files: one file with the code until "CMDpartHD" and the second from "CMDpartHD" and then read the two files and join them to create the hta or still better: 2/ have a single hta and transfer the variable "CMDpartHD" via command line parameter.
  16. Goddamn "Replace all" buttons! (code corrected. I hope ot works now)
  17. That's fine. We will wait. (just saying the problem is still there thought)
  18. Here is the code cleaned-up Sub parseFile() Dim ts, t, pos, pos2, pos3, i, tmp1, oExec, objSel1, temppiFile Set objSel1 = window.document.getElementById("select1") temppiFile = Objfso.GetSpecialFolder(1) & "\temp.txt" ObjShell.Run "%comspec% /c Imagex /info " _ & myFilepath & objSel1.options(objSel1.selectedindex).text _ & " > " & temppifile, 0, True i=-1 Redim Names(0) Redim Indx(0) Redim Desc(0) If objFso.FileExists(temppifile) Then Set ts = objFso.OpenTextFile(temppifile, 1) Do Until ts.AtEndOfStream t = ts.ReadLine pos = InStr(1, t, "<NAME>", 1) pos2 = InStr(1, t, "<IMAGE>", 1) pos3 = InStr(1, t, "<DESCRIPTION>", 1) If pos2 > 0 Then i=i+1 Redim Preserve Indx(i) Redim Preserve Names(i) Redim Preserve Desc(i) Desc(i) = "NO DESCRIPTION" If Len(t) > pos + 13 Then tmp1 = Right(t, Len(t) - pos2 -13) If Len(tmp1) > 3 Then Indx(i) = Left(tmp1, Len(tmp1) -3) End If End If If pos > 0 And Len(t) > pos + 5 Then tmp1 = Right(t, Len(t) - pos -5) If Len(tmp1) > 8 Then Names(i) = Left(tmp1, Len(tmp1) -8) End If End If If pos3 > 0 And Len(t) > pos3 + 12 Then '---Here was the error tmp1 = Right(t, Len(t) - pos3 -12) If Len(tmp1) > 15 Then Desc(i) = Left(tmp1, Len(tmp1) -15) End If End If End If Loop End If enumDirs End sub
  19. Try this, it should be bullet proof: Sub parseFile() Dim objTextFile, sReadLine, pos, pos2, pos3, i, tmpStr1, oExec, objSel1, strFile, objSel2, SysFolder2,temppiFile Set objSel1 = window.document.getElementById("select1") Set SysFolder2 = Objfso.GetSpecialFolder(1) temppiFile = SysFolder2 & "\temp.txt" strFile = myFilepath + objSel1.options(objSel1.selectedindex).text ObjShell.Run "%comspec% /c Imagex /info "+strFile+" > "+temppifile,0,True i = -1 Redim strNames(0) Redim strIndx(0) Redim strDesc(0) If objFso.FileExists(temppifile) Then Set objTextFile = objFso.OpenTextFile(temppifile, 1) Do Until objTextFile.AtEndOfStream sReadLine = objTextFile.ReadLine pos = Instr(1, sReadLine, "<NAME>", 1) pos2 = Instr(1, sReadLine, "<IMAGE>", 1) pos3 = Instr(1, sReadLine, "<DESCRIPTION>", 1) If pos2 > 0 Then i=i+1 Redim Preserve strIndx(i) Redim Preserve strNames(i) Redim Preserve strDesc(i) strDesc(i) = "NO DESCRIPTION" If Len(sReadLine) > pos + 13 Then tmpStr1 = Right(sReadLine, Len(sReadLine) - pos2 -13) If Len(tmpStr1) > 3 Then strIndx(i) = Left(tmpStr1, Len(tmpStr1) -3) End If End If If pos > 0 And Len(sReadLine) > pos + 5 Then tmpStr1 = Right(sReadLine, Len(sReadLine) - pos -5) If Len(tmpStr1) > 8 Then strNames(i) = Left(tmpStr1, Len(tmpStr1) -8) End If End If If pos3 > 0 And Len(sReadLine) > pos3 + 12 Then '---Here was the error tmpStr1 = Right(sReadLine, Len(sReadLine) - pos3 -12) If Len(tmpStr1) > 15 Then strDesc(i) = Left(tmpStr1, Len(tmpStr1) -15) End If End If End If Loop End If enumDirs End sub
  20. I'v got the errors many times today and as late as 5 minutes ago. Almost impossible to use the board at the moment because of this. Also if I enable activeX (which is disabled by default) pages take ages to download...
  21. 4.6 -New: Support for Windows XP and other OSes using the same DOS version. -New: Displaying system file versions (exe, dll etc) for added and modified files -Improved: Slightly faster -Improved: Option to shrink or expand table cells containing long names -Improved: Style (color, table, font etc) and better html code -Improved: Focus directly on the "comment" box -Improved: Displaying the folder being checked when this one takes a long time to do -Fixed: Potential mistakes when more than 50 files have been added or missing in the same folder -Fixed: White space preceding file names when the hour in the file date is followed by "a" or "p" (very minor bug) -Fixed: Main window hiding the taskbar when enlarged for viewing details -Changed: Location of the program's registry entries
  22. KeX-------------- 27776 views Rev Pack-------- 34615 views uSP 3----------- 269413 views Autopatcher---- 257744 views Sure, no one wants these craps. We are all using ssplus visual patches "without N$ spam" that loads 1/1000th of a second faster. (downside: everything is displayed in Polish but that's a very minor bug) LOL
  23. uSP3.0 beta 3 is stable as far as I'm concerned. IMO it has been tested long anough to drop the beta statu. When Gape said "beta" he was very conservative. AFAIMC, until a new version pops up, uSP3.0 is final.
  24. You can copy your system and program files to a DVD, another HD etc. Then when you need to restore your system, just re-copy the files back in DOS mode. (The level of reliability of such backup/restore method has never been duplicated) If you don't have such copy, reinstall over it.
×
×
  • Create New...