kenedy

kTool (just another software selector)

146 posts in this topic

Hi Sin! yes, I still want that code, can you post it here? or you can send me an email?

I added the Win7 line to the 1.2c version, but I haven't test it yet.

Andee

0

Share this post


Link to post
Share on other sites

Heres the code. Certainly not optimised (slower reading in file than 1.2c). Wont let me upload exe as its larger than 200k

Ignore the line "; THIS IS WHERE IT GOES ALL WRONG!", it was were I added the 'install in order listed' code. :)

kToolv1.2d_unoffical.zip

Edited by Sin_of_Nature
0

Share this post


Link to post
Share on other sites

I'm working on KTool 1.2d to handle ZIP or 7z files.

My software database is on a external hard drive, and I may use it on untrusted maybe infected computers. Therefore, I'm storing each driver or software in a zip file to protect my files against viruses.

I'm about to test some new instructions in INI file to use 7Za.exe to unzip a software in a temp folder, and then run an EXE or MSI file.

Do you feel theses changes useful ?

Edited by Necros
0

Share this post


Link to post
Share on other sites

Hi,

Not sure if you still use this, but the IsAdmin() function call does not work correctly under Vista and Windows 7.


Func CheckAdmin() ;Check if user has administrator rights
If IsAdministrator()=0 Then
If MsgBox (4,"","Administrator rights required. Continue?") = 7 then Exit
EndIf
EndFunc ;CheckAdmin

; Replacement function for IsAdmin
Func IsAdministrator($sUser = @UserName, $sCompName = ".")
Local $aCall = DllCall("netapi32.dll", "long", "NetUserGetInfo", "wstr", $sCompName, "wstr", $sUser, "dword", 1, "ptr*", 0)
If @error Or $aCall[0] Then Return SetError(1, 0, False)
Local $fPrivAdmin = DllStructGetData(DllStructCreate("ptr;ptr;dword;dword;ptr;ptr;dword;ptr", $aCall[4]), 4) = 2
DllCall("netapi32.dll", "long", "NetApiBufferFree", "ptr", $aCall[4])
Return $fPrivAdmin
EndFunc

The IsAdministrator was not written by me, some smart person on the AutoIt forum did. Works a treat though.

Zip function would be usefull. My next step to be able to adjust the install order (+ and - buttons) window so you can move applications up and down the install list.

Sin

I'm working on KTool 1.2d to handle ZIP or 7z files.

My software database is on a external hard drive, and I may use it on untrusted maybe infected computers. Therefore, I'm storing each driver or software in a zip file to protect my files against viruses.

I'm about to test some new instructions in INI file to use 7Za.exe to unzip a software in a temp folder, and then run an EXE or MSI file.

Do you feel theses changes useful ?

Edited by Sin_of_Nature
0

Share this post


Link to post
Share on other sites

The ReturnOSVersion function should contain:

Case $VER = "WIN_7"
$OS = "Windows 7"
Case $VER = "WIN_VISTA"
$OS = "Windows Vista"
Case $VER = "WIN_XP"
$OS = "Windows XP"
Case $VER = "WIN_2000"
$OS = "Windows 2000"
Case $VER = "WIN_98"
$OS = "Windows 98"
Case $VER = "WIN_ME"
$OS = "Windows ME"
Case $VER = "WIN_95"
$OS = "Windows 95"
Case $VER = "WIN_NT4"
$OS = "Windows NT4"

What you do with the new responses in that source is your own design. Note you can get the version simply by returning the @OSVersion macro:

MsgBox (0, "OS Version", @OSVersion)

For example:

OSVersion_Autoit.png

'UNKNOWN" on windows 8

0

Share this post


Link to post
Share on other sites

As you can CLEARLY see the code does not exist for win 8...

Case $VER = "WIN_7"

$OS = "Windows 7"

Case $VER = "WIN_VISTA"

$OS = "Windows Vista"

Case $VER = "WIN_XP"

$OS = "Windows XP"

Case $VER = "WIN_2000"

$OS = "Windows 2000"

Case $VER = "WIN_98"

$OS = "Windows 98"

Case $VER = "WIN_ME"

$OS = "Windows ME"

Case $VER = "WIN_95"

$OS = "Windows 95"

Case $VER = "WIN_NT4"

$OS = "Windows NT4"

0

Share this post


Link to post
Share on other sites

As you can CLEARLY see the code does not exist for win 8...

Case $VER = "WIN_7"

$OS = "Windows 7"

Case $VER = "WIN_VISTA"

$OS = "Windows Vista"

Case $VER = "WIN_XP"

$OS = "Windows XP"

Case $VER = "WIN_2000"

$OS = "Windows 2000"

Case $VER = "WIN_98"

$OS = "Windows 98"

Case $VER = "WIN_ME"

$OS = "Windows ME"

Case $VER = "WIN_95"

$OS = "Windows 95"

Case $VER = "WIN_NT4"

$OS = "Windows NT4"

i hope this ktool can work on windows 8,,i was add on code WIN_8 and not working, so i try the @OSVersion macro: MsgBox (0, "OS Version", @OSVersion),,and "UNKNOWN" Message Appear,,

0

Share this post


Link to post
Share on other sites

Add this to the ReturnOSVersion function:

Case $VER = "8"

$OS = "Windows 8"

0

Share this post


Link to post
Share on other sites

thanks,,solved,,i was update autolt version to 3.3.8.1 :

solved.png

solved2.png

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.