WindSLIC boot CD

Discussion in 'MDL Projects and Applications' started by nononsence, Sep 3, 2009.

  1. Opa

    Opa MDL Addicted

    Jul 29, 2009
    679
    969
    30
    Why do we need it to run on XP? who dare using XP? :D
    no i'm kidding, but seriously I believe that there is no need to care about XP compatibly, since XP isn't compatible with this method of activation anyway...
     
  2. PAYMYRENT

    PAYMYRENT MDL Developer

    Jul 28, 2009
    1,460
    421
    60
    #122 PAYMYRENT, Oct 13, 2009
    Last edited: Oct 13, 2009
    i think its just to be safe and i still use xp on my laptop because it runs all my music production programs faster
     
  3. nononsence

    nononsence MDL Addicted

    Aug 18, 2009
    806
    826
    30
    I do some of my work on XP so, often times Im running this in VS
    while debugging, it should failsafe and with the only option to close the app.
     
  4. PAYMYRENT

    PAYMYRENT MDL Developer

    Jul 28, 2009
    1,460
    421
    60
    i can live with the debugging error i just wanted to know if anyone knew how to stop it from happening
     
  5. HotCarl

    HotCarl MDL Addicted

    Jul 21, 2009
    830
    17
    30
    #125 HotCarl, Oct 14, 2009
    Last edited by a moderator: Apr 20, 2017
    ...just a quick question:

    I was looking at your source...looks ok...and came across your Unmount() procedure.

    Code:
        Public Sub Unmount()
    
            '==================================================================================
            'unmount System Volume
            '==================================================================================
    
            Dim mountvol As New ProcessStartInfo("mountvol")
            mountvol.WindowStyle = ProcessWindowStyle.Hidden
    
            If isMounted = 0 Then
                If Not TargetDrive = "C:" Then
                    mountvol.Arguments = (" " & TargetDrive & " /D ")
                    Process.Start(mountvol)
                    isMounted = 0
                End If
            End If
    
        End Sub
    
    I was wondering why you check if "isMounted = 0", then set it to 0 within the code of the If block...? Because isMounted will already be 0 if it enters the If block, so the "isMounted = 0" seems unneeded...

    Or should the "If isMounted = 0 Then" be "If isMounted = 1 Then" instead? (that is my guess...)
     
  6. Reign_Of_Freedom

    Reign_Of_Freedom MDL Expert

    Aug 1, 2009
    1,246
    467
    60
    He has to call the procedure for the If block to function. Although i'll be corrected if i am wrong lol.
     
  7. HotCarl

    HotCarl MDL Addicted

    Jul 21, 2009
    830
    17
    30
    #127 HotCarl, Oct 14, 2009
    Last edited: Oct 14, 2009

    I realize that...lol.

    My point is that he sets a variable to zero after he checks whether it is zero...
    Basically, isMounted must be zero to enter the If block... So why then set it to zero inside the If block if it already MUST be zero to even enter the If... Get me?

    Either "If isMounted = 0 Then" must instead be changed to "If isMounted = 1 Then" <which is what I think must be done...>

    ...or the "isMounted = 0" should be removed from inside the If block because it is pointless...
     
  8. Reign_Of_Freedom

    Reign_Of_Freedom MDL Expert

    Aug 1, 2009
    1,246
    467
    60
    I follow you now. We'll just have to wait and see what he says about it. Been awhile since i used .Net
     
  9. HotCarl

    HotCarl MDL Addicted

    Jul 21, 2009
    830
    17
    30
    #129 HotCarl, Oct 14, 2009
    Last edited by a moderator: Apr 20, 2017
    1 last question...

    (code from Target_Drive() function)
    Code:
            '==================================================================================
            'mount System Volume
            '==================================================================================
    
            If isMounted = 0 Then
                For Each objMgmt In Volume.Get
                    If objMgmt("SystemVolume") = True Then
                        objMgmt("DriveLetter") = TargetDrive
                        objMgmt.Put()
                        isMounted = 1 '<--- set variable to 1 here since drive is now mounted...?
                        Exit For
                    End If
                Next
            End If
    
    Since you are using the "isMounted" variable to determine whether or not the system volume is mounted, should you then set isMounted = 1 within the If statement in the For loop (since it seems that you have apparently mounted the drive at this point)...or am I missing something? <see my comment in the code>
     
  10. PAYMYRENT

    PAYMYRENT MDL Developer

    Jul 28, 2009
    1,460
    421
    60
    #130 PAYMYRENT, Oct 14, 2009
    Last edited by a moderator: Apr 20, 2017

    i think you missed the exit for
     
  11. nononsence

    nononsence MDL Addicted

    Aug 18, 2009
    806
    826
    30
    no hot carl is right what happend was the before the unmount code look liked this

    If Not TargetDrive = "C:" Then
    mountvol.Arguments = (" " & TargetDrive & " /D ")
    Process.Start(mountvol)
    isMounted = 0
    End If


    but then it would unmount user mounted system volume, I felt that leaving
    the volume mounted if the user had manualy mounted it would be better
    so I changed it to what it is now, the extra isMounted = 0 was put there in
    the first place to deal with running the app over and over again without
    closing durring debugging.
     
  12. Reign_Of_Freedom

    Reign_Of_Freedom MDL Expert

    Aug 1, 2009
    1,246
    467
    60
    Ahh that explains it.
     
  13. HotCarl

    HotCarl MDL Addicted

    Jul 21, 2009
    830
    17
    30

    OK...so you only use the isMounted variable to check whether the user has previously mounted the system partition before running the program...not whether the system partition is mounted at all... Got it, makes much more sense now. The variable name threw me off I guess.
     
  14. omdhar

    omdhar MDL Junior Member

    Aug 1, 2009
    94
    40
    0
  15. nononsence

    nononsence MDL Addicted

    Aug 18, 2009
    806
    826
    30
    what is the error, I cant read the small pixelated text
    you can remove the file decode and file check, but it
    will open up the risk of a resource replacement attack
    that could be used to install malware.
     
  16. omdhar

    omdhar MDL Junior Member

    Aug 1, 2009
    94
    40
    0
    Sorry, Image updated. Its showing invalid character in 64-bit string.
     
  17. nononsence

    nononsence MDL Addicted

    Aug 18, 2009
    806
    826
    30
  18. nononsence

    nononsence MDL Addicted

    Aug 18, 2009
    806
    826
    30
    added Starter support
    added sony slic and certificate
    updated HP and Toshiba tosinv certificate to 2.1
     
  19. kevinrogers1977

    kevinrogers1977 MDL Novice

    Oct 12, 2009
    4
    0
    0
    #140 kevinrogers1977, Oct 21, 2009
    Last edited: Oct 21, 2009

    Attached Files: