Microsoft
Software
Hardware
Network
Question : Parse output of bcdedit with script in winpe
I am booting a pc into WinPE. I need to run the command bcdedit and parse the output for the GUID to use in another command. I can use the For /F loop to get the second arguments but I get the second argument from each line. I need to narrow it down to just the GUID {3c4924ac-89ee-11df-bf77-7
8e7d18646f
a}
Need to do this from a batch file running in winpe.
Example output from bcdedit.
BCDEDIT
Windows Boot Manager
__________________________
_
identifier {Bootmgr}
device partition=c:
description Windows Boot Manager
local en-us
.....more stuff
Windows Legacy OS Loader
__________________________
___
identifier {ntldr}
device partition=c:
path \ntldr
descriptions Earlier Version of Windows
Windows Boot Loader
__________________________
___
identifier {default}
device vhd==[c:]\Widnows\iamges\0
00\pdiusys
.vhd
path \windows\system32\winload.
exe
description Windows 7 Boot to VHD
local en-US
inherit {bootlaodersettings}
osdevice vhd==[c:]\Widnows\iamges\0
00\pdiusys
.vhd
resumeobject {3c4924ac-89ee-11df-bf77-7
8e7d18646f
a}
nx optin
detecthal Yes
Answer : Parse output of bcdedit with script in winpe
try
P.StartInfo.Arguments = scriptfile + s.Filename;
-->
P.StartInfo.Arguments = "\"" + scriptfile +"\" "+ s.Filename;
Random Solutions
Unable to issue commands to Tivoli Storage Manager 6.1 Server using the Administration Center Console
Is it possible to apply style, such as bold or color, to a single line in TMemo1 control?
Windows Service crashing on one machine, not on the other
Wireless LAN , Larger Scale
SWF object with FLVPlayback component
Whats wrong with my css?
Event code: 3005 - An unhandled exception has occurred with custom ASP.Net app
SBS 2008 Server running extreamly slow
Reading data off Raid 0
HELO server unrecognized command