DosTips.com

A Forum all about DOS Batch
It is currently 26 Jul 2016 23:42

All times are UTC-06:00




Post new topic  Reply to topic  [ 21 posts ]  Go to page Previous 1 2
Author Message
PostPosted: 31 Aug 2012 13:00 
Offline

Joined: 21 Nov 2010 08:07
Posts: 233
Location: At My Computer
Wow! Danke schön! Ed for the updated code. Yep I am a big W7 fan can you tell? lol. Your code is only 3kb and working Great for OEMs, I won't be able to test on a Non-Oem machine til late next week, but I see you have set "$manufacturer=custom" but do not
have a goto Custom like Squashman's post, so will it work with a non-oem or does that need to be added? The custom thing was why this thread started in the first place.

btw..I am not familiar with :§init ( paramRAW ) what does that do? :?:


Top
   
PostPosted: 31 Aug 2012 13:16 
Offline
Expert

Joined: 16 May 2011 08:21
Posts: 1433
Location: Flanders(Belgium)
Dos_Probie wrote:
but do not have a goto Custom like Squashman's post
If at any point in time you use goto, look very carefully whether you really need it.
In 95% of cases it can be replaced with a 'call cmd /c exit %errorLevel%'.
The only valid cases of using goto is when breaking a loop 'for /l %%? in () do goto :breakFor'.
Dos_Probie wrote:
I am not familiar with :§init ( paramRAW ) what does that do? :?:
Nothing, to DOS everything after a label is comment.


Top
   
PostPosted: 31 Aug 2012 14:15 
Offline
Expert

Joined: 23 Dec 2011 13:59
Posts: 3146
Hi Dos Probie,
Ed is setting the manufacturer name to custom first and then it will be changed if it finds a new manufacturer in the wmic command. So it works for OEM and custom.

Ed, thanks for writing the code. No computer for me for a few more days until I get back home.


Top
   
PostPosted: 31 Aug 2012 17:35 
Offline

Joined: 21 Nov 2010 08:07
Posts: 233
Location: At My Computer
Thanks for the info Squash, So do i need a :Custom label with the code added if it doesnt find one of the above OEMs listed or is just going to automatically
do the install as long as my folder is listed Custom :?:


btw, yes I did get the Bill trojan virus thats been going around on here but I got him quarantine now and all is back to normal again .. :mrgreen:


Top
   
PostPosted: 31 Aug 2012 18:05 
Offline
Expert

Joined: 23 Dec 2011 13:59
Posts: 3146
You shouldn't need any redundant code at all for your non oem computers.
If the directory structure and file names are consistent with the oem and non oem computers then you only need one set of code to do what you want.


Top
   
PostPosted: 31 Aug 2012 18:19 
Offline

Joined: 21 Nov 2010 08:07
Posts: 233
Location: At My Computer
Sounds good...I will test it out on one of my custom built machines when
I return home next week.. 8)


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 21 posts ]  Go to page Previous 1 2

All times are UTC-06:00


Who is online

Users browsing this forum: Yahoo [Bot] and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited