Extract specific part of string to a variable

February 10, 2011 at 06:59:28
Specs: Windows XP
Hi,

I'd like to extract this string "23857,849069983" from the below file extract and assign it to a variable called e_key


Copyright (c) 2000, 2008, Oracle and/or its affiliates.
All rights reserved.


Public Key for Encryption: 23857,849069983
Private Key for Decryption: 9608593,849069983

MaxL Shell completed

Any help guys, I'm pulling my hair out here!

Thanks


See More: Extract specific part of string to a variable

Report •


#1
February 10, 2011 at 08:11:53
@for /F "tokens=5" %%j in ('type "your_file" ^| find "Encryption"') do set e_key=%%j


Report •

#2
February 10, 2011 at 08:36:19
Genius! Thank-you v much IVO

Report •

Related Solutions


Ask Question