Jump to content

krovax

Member
  • Posts

    6
  • Joined

  • Last visited

  • Donations

    0.00 USD 
  • Country

    Canada

About krovax

krovax's Achievements

0

Reputation

  1. Woot!!!!!!!! When I tried the last script it didn't worked (I had no access to c:) but then I changed the path to Z: and the file was there. Thank you so much guys!!!! For my personnal learning, what is abspath? and how to work with it?
  2. Yes I have tried that before but my problem was that I had to give a name for the log file and it was always the same name. I know I could have change the name after but when I will wipe 10 HDD at the same time all my file will write over each other.
  3. Still same problem, the script start, another windows open and close really fast and there is no text file create on the share and no error message. If anyone have an idea of how we could correct that or do it another way that would be awesome I was thinking that maybe I could save the file on the ram drive (x:) into "value".qwe and then copy *.qwe on z: What do you guys think of that?
  4. And how yould you guys write what I want? Input box, take that value entered and use it in that way diskpart /s diskpart.txt>z:\"value".txt *I didn't refresh before posting, sorry
  5. This is my problem, I don't have any error. Just wanted to see if the script was looking fine (cause like I said I am a total nub in vbs). The only thing I can see is that there is another command prompt opening and there is a dispart display then it shutdown and nothing more, not even a log is created. The dispart cclean all command should take about 10 minutes and I should have a log on my mapped drive.
  6. Hi guys, I'm a total newb in scripting and I hae the following need: I want to use Winpe 2.0 to wipe hardrive with diskpart and have a log of that. I want my log file to have the serial number of the drive as file name. I know that there is no good way to get the serial number of HDD (IDE or SATA) so I am using a bar code reader. The script should pop a text box so I can scan the serial number on the hard drive and keep that value to name my log file. here is a script someone made from me but we are unable to find what it's not working: Dim Reponse Dim AbsPath:AbsPath = Replace(WScript.ScriptFullName, WScript.ScriptName, "") ' This variable DOES have a trailing '\' Reponse = inputbox("write a value,Cancel or no value to exit the script","Diskpart") If Answer = "" Then Wscript.Quit End if Call ExecuteProg(AbsPath & "diskpart ", Answer) Sub ExecuteProg(PathAndProgName, Var1) Set WshShell = WScript.CreateObject("WScript.Shell") WshShell.Run PathAndProgName & "/s diskpart.txt>z:\" & Var1 & ".txt" End sub (there was a bit of french in here so I tried to rename it to english) in my startnet.cmd there is a command to map a drive to a network share then I am running the vbs. The vbs is supposed to start diskpart, run the script, and redirect the output to the mapped drive and use the value as a log file name. Now when we execute the vbs dispart is running but it's not using the the clean all command that he is supposed to do and there is no log file created. Thx for your help and don't be shy to ask me question if there is something bizarre (english is my second language so I'm trying to be as clear as I can)
×
×
  • Create New...