Multi OEM/Retail Project

Discussion in 'MDL Projects and Applications' started by The_Guardian, Nov 8, 2014.

Thread Status:
Not open for further replies.
  1. The_Guardian

    The_Guardian Contributor

    May 7, 2012
    2,054
    6,803
    90
    #201 The_Guardian, Jan 6, 2015
    Last edited: Jan 7, 2015
    (OP)
    Sorry its because the whole cmd file was made to run from current directory.....the sfx file extracts to Temp folder so if ran from there the current directory is the Temp folder. The text file according to the vbs file echo's it will always write to Temp folder location. I didn't know how in vb scripting to write file to "%~dp0" (current directory). Sorry I was getting confused. lol Hope this clears things up for you.

    Update: I added "%~dp0" to vbs echo to replace the %Temp% location and it worked for finding the current directory but still only blank txt file. grrr lol I will work on this tomorrow if I have time. I am done for tonight. Its in the cmd file that the problem is arising...I am missing something because the other vbs files run so ...

    I have even tried turning off uac and that did not make any difference. Also tried adding admin rights to vbs file without success. Seems as if the vbs if ran from within the batch file cant transfer the key to the text file.

    If nothing else I will drop this registry key query for I have a complete vbs file for all system info so I don't really need it. vbs files are such a pain to run from a batch file and it isn't worth the headache since other tools can query the key.
     
  2. abbodi1406

    abbodi1406 MDL KB0000001

    Feb 19, 2011
    17,618
    93,568
    340
    View attachment OEM-CD.zip

    IF EXISTS ".\QueryKey.vbs" (".\QueryKey.vbs")
    it's EXIST

    NBBBB-BBBB-BBBBB-BBBBB should be NBBBB-BBBBB-BBBBB-BBBBB-BBBBB (missing B in second group)

    IF EXIST ".\RegKey.txt" for /f "tokens=2 delims=:" %%A in ('find "-" .\RegKey.txt') do (set REGKEY=%%A)
    could be
    IF EXIST ".\RegKey.txt" for /f %%A in (RegKey.txt) do (set REGKEY=%%A)
    by removing "Installed Key:" & of vbs script

    and at final :LOOP phase, lines= should be 30 or 31 so OEM INFORMATION FOR THIS MACHINE appear
     
  3. The_Guardian

    The_Guardian Contributor

    May 7, 2012
    2,054
    6,803
    90
    #203 The_Guardian, Jan 7, 2015
    Last edited: Jan 7, 2015
    (OP)
    RegKey.txt file still empty on win 8.1. Think it is the save(data) in the vbs file that is the issue with win8.x. The vbs file runs obviously since the RegKey.txt file is created but seems it cant write to it to include the key in win 8.x. This is what I was saying earlier, what works in one OS might not work in another OS.

    I am dropping the installed key query because for the life of me and others it just wont work when running in a batch file. It has to do with the key saving the data in win 8.x so all this is doing is irritating me. I have tried multiple saving types all without success. You can click on the vbs file and it works correctly, just not ran from batch file. There are other tools if you need to know your install key in registry. We are done with this.
     
  4. abbodi1406

    abbodi1406 MDL KB0000001

    Feb 19, 2011
    17,618
    93,568
    340
  5. The_Guardian

    The_Guardian Contributor

    May 7, 2012
    2,054
    6,803
    90
    #205 The_Guardian, Jan 7, 2015
    Last edited: Jan 7, 2015
    (OP)
    Unable to open registry key. If I click on your new vbs file (adding :: to stop deletion in cmd file) it opens window with key but nothing in cmd window about key. Any of these vbs files run when manually clicked...just not ran from cmd file. Win 8.x is stopping it even with uac turned off.
     
  6. skolar

    skolar MDL Novice

    May 5, 2014
    33
    39
    0
    Have all 'Installed Key' tests so far, been ran on 64bit OS's only?
     
  7. The_Guardian

    The_Guardian Contributor

    May 7, 2012
    2,054
    6,803
    90
    #207 The_Guardian, Jan 7, 2015
    Last edited: Jan 7, 2015
    (OP)
    Cant get it to run correctly within a sfx file....that's the problem I found out in the end. I can run the cmd file myself with little editing from anywhere and click on cmd file and it works perfect. For some odd reason win 8.x doesn't like running certain cmds no matter if uac is off or on from sfx files. I decided to just drop it. I have a vbs file I created a while back that gets detailed info. This was just an added feature I was "trying" but did not succeed.

    skolar, can you share those 4 oems you found so I can add them to the project? I got the query tool to show service tag and that is all I am doing to that tool. I would like to add the other oems since Alphawaves new or should I say updated project will be released soon and would like to test the new oems with it. Thanks in advance.
     
  8. user_hidden

    user_hidden MDL Expert

    Dec 18, 2007
    1,034
    1,062
    60
    #209 user_hidden, Jan 7, 2015
    Last edited by a moderator: Apr 20, 2017
    have you tried any 3rd party cmdline tools to get the key and parse the file?
    something like nirsoft produkey.
    you can pipe the keys to a txt file

    Code:
    produkey.exe /WindowsKeys 1 /OfficeKeys 0 /IEKeys 0  /SQLKeys 0 /ExchangeKeys 0  /stab "" >> key.txt
     
  9. skolar

    skolar MDL Novice

    May 5, 2014
    33
    39
    0
    #210 skolar, Jan 7, 2015
    Last edited by a moderator: Apr 20, 2017
  10. The_Guardian

    The_Guardian Contributor

    May 7, 2012
    2,054
    6,803
    90
    #211 The_Guardian, Jan 7, 2015
    Last edited: Jan 7, 2015
    (OP)
    Not going to add the installed registry key. Too much of a pain. The problem is the sfx file. I don't want to keep adding 3rd party tools....why not just use a 3rd tool to find out in the first place? lol Anyways this subject is history. Updated query tool and main project link on first post.

    The reason I use a sfx file in the first place is so anyone can update it if need be....I can use other methods but it would no longer be open source. In life, we have to take and give. ;)
     
  11. The_Guardian

    The_Guardian Contributor

    May 7, 2012
    2,054
    6,803
    90
    #212 The_Guardian, Jan 7, 2015
    Last edited by a moderator: Apr 20, 2017
    (OP)
  12. Computer Fixer

    Computer Fixer MDL Member

    Jan 5, 2010
    165
    30
    10
    Great project Guardian- very useful!

    Thanks very much....:worthy:
     
  13. l33tissw00t

    l33tissw00t MDL Addicted

    Dec 6, 2012
    819
    522
    30
  14. The_Guardian

    The_Guardian Contributor

    May 7, 2012
    2,054
    6,803
    90
    #216 The_Guardian, Jan 8, 2015
    Last edited: Jan 8, 2015
    (OP)
    None of those methods work unfortunately. The problem I will say again is the sfx file in win 8.x.....windows will not allow it to run properly. Manually running the cmd prompt from temp directory works perfect like it should so it isn't the scripting but the sfx isn't allowed to run certain cmds. There is no solution to this other then me making the tool closed source to resolve it. So I will ask....do you all really want to close source this tool or leave it be and use above vbscript that I provided to look that up manually? It doesn't matter to me.

    Does anyone know how to create a sfx file using 7zip? I cant for the life of me find info online how to do it step by step. Would like to try it instead of WinRAR to see if problem is specific to WinRAR or all sfx's.
     
  15. Mr.X

    Mr.X MDL Guru

    Jul 14, 2013
    8,554
    15,642
    270
    Release a closed source version while an open source at the same time well. Having both, people will have options to pick up the most convenient.
     
  16. Tito

    Tito Admin / Adviser
    Staff Member

    Nov 30, 2009
    18,989
    19,622
    340
  17. The_Guardian

    The_Guardian Contributor

    May 7, 2012
    2,054
    6,803
    90
    Doesn't matter what app you use to make sfx file....it will never run correctly in windows 8.x. Just tried 7zip and it also failed. Seriously ppl lets drop this.....its not possible with the current process. I know ppl want their cake and eat it also but that isn't going to happen in this case. Why create two projects for the tool when I already provided a vbscript to do the same? Seriously, lets move on.
     
  18. Mr.X

    Mr.X MDL Guru

    Jul 14, 2013
    8,554
    15,642
    270
    It's fine whatever you decide man :hug2:
    Just don't drop this project please :worthy: :D