1
How to find out the architecture of OS installed and get only the value 32 or 64 in Windows?
With wmic os get osarchitecture
I get :
OSArchitecture
64-bit
I only want 32
or 64
without OSArchitecture
.
1
How to find out the architecture of OS installed and get only the value 32 or 64 in Windows?
With wmic os get osarchitecture
I get :
OSArchitecture
64-bit
I only want 32
or 64
without OSArchitecture
.
2
for /f "tokens=1 delims=-" %a in ('wmic os get osarchitecture ^| find "bit"') do @echo %a
I know it's not exactly the same as the OP's solution but I just wanted to improve it a bit. – Karan – 2015-06-09T12:27:40.827
Is using Powershell an acceptable option for your situation? – EBGreen – 2015-06-08T15:10:19.547
No, I am using simple commands in cmd, i was wondering perhaps there's an equivalent to "grep" or "cut" (Linux) in Windows. – Aziz – 2015-06-08T15:14:19.370
possible duplicate of Is it possible to get ONLY the Drive Label using WMIC?
– Patrick Seymour – 2015-06-08T15:20:08.5832@Aziz - Post solutions as answers, don't edit your question, to include the solution. – Ramhound – 2015-06-08T15:43:52.050
@Aziz Please read Can I answer my own question?
– DavidPostill – 2015-06-08T16:38:55.130I did it @DavidPostill, I put the answer, but it doesn't appear! – Aziz – 2015-06-08T17:24:02.520