Jump to content

EzSkin_1-2-3 (exe) 1,000+ Skin & Button Choices


Valuater
 Share

Recommended Posts

Works for me....

(Requires the zip file above)

#include <GUIConstants.au3>
#include <EzSkin2.au3>

$EzGUI = EzSkinGUICreate("MyEzSkinDemo",600,450)
$EzIcon = EzSkinIcon($EzGUI)

$Button1 = EzSkinButton("EzSkin Button", 100, 80, 200, 30) ;, $font_color)
GUICtrlCreateLabel("EzSkin Can show pics too!", 150, 130, 200, 20) ; use this line to create your pics
GUICtrlSetState( -1, $GUI_HIDE)

$Button2 = EzSkinButton("EzSkin Button", 100, 180, 200, 30) ;, $font_color)
GUICtrlCreateLabel("EzSkin Can show pics too!", 150, 230, 200, 20) ; use this line to create your pics
GUICtrlSetState( -1, $GUI_HIDE)

$Button3 = EzSkinButton("EzSkin Button", 100, 280, 200, 30) ;, $font_color)
GUICtrlCreateLabel("EzSkin Can show pics too!", 150, 330, 200, 20) ; use this line to create your pics
GUICtrlSetState( -1, $GUI_HIDE)


$Button4 = EzSkinButton("EzSkin Button", 100, 380, 200, 30) ;, $font_color)
GUICtrlCreateLabel("", 150, 430, 200, 2) ; use this to end the thumb nail if there is no more pics


GUISetState()

While 1
    EzSkinOver2() ;added this
    $msg = GUIGetMsg()
    If $msg = $EzIcon[1] Then Exit
    If $msg = $EzIcon[2] Then GuiSetstate(@SW_MINIMIZE, $EzGUI)
    If $msg = $Button1  Then MsgBox(64,"EzSkin", "The Skin is operating properly... Thanks    ")
WEnd

8)

NEWHeader1.png

Link to comment
Share on other sites

Working with pics...

#include <GUIConstants.au3>
#include <EzSkin2.au3>

$EzGUI = EzSkinGUICreate("MyEzSkinDemo",600,500)
$EzIcon = EzSkinIcon($EzGUI)

$Button1 = EzSkinButton("EzSkin Button", 100, 80, 200, 30) ;, $font_color)
;GUICtrlCreateLabel("EzSkin Can show pics too!", 150, 130, 200, 20) ; use this line to create your pics
$pic1 = GUICtrlCreatePic("C:\WINDOWS\Help\Tours\htmlTour\connected_data_big.jpg", 350, 150, 131, 155)
GUICtrlSetState( $pic1, $GUI_HIDE)

$Button2 = EzSkinButton("EzSkin Button", 100, 180, 200, 30) ;, $font_color)
;GUICtrlCreateLabel("EzSkin Can show pics too!", 150, 230, 200, 20) ; use this line to create your pics
$pic2 = GUICtrlCreatePic("C:\WINDOWS\Help\Tours\htmlTour\connected_multiple_big.jpg", 350, 150, 131, 155)
GUICtrlSetState( $pic2, $GUI_HIDE)

$Button3 = EzSkinButton("EzSkin Button", 100, 280, 200, 30) ;, $font_color)
;GUICtrlCreateLabel("EzSkin Can show pics too!", 150, 330, 200, 20) ; use this line to create your pics
$pic3 = GUICtrlCreatePic("C:\WINDOWS\Help\Tours\htmlTour\connected_networks_big.jpg", 350, 150, 131, 155)
GUICtrlSetState( $pic3, $GUI_HIDE)


$Button4 = EzSkinButton("EzSkin Exit", 100, 380, 200, 30) ;, $font_color)
GUICtrlCreateLabel("", 350, 150, 100, 20) ; use this to end the thumb nail if there is no more pics
GUICtrlSetState( -1, $GUI_HIDE)

GUISetState()

While 1
    EzSkinOver2() ;added this
    $msg = GUIGetMsg()
    If $msg = $EzIcon[1] Then Exit
    If $msg = $EzIcon[2] Then GuiSetstate(@SW_MINIMIZE, $EzGUI)
    If $msg = $Button1  Then MsgBox(64,"EzSkin", "The Skin is operating properly... Thanks    ")
    If $msg = $Button4  Then Exit
WEnd

8)

NEWHeader1.png

Link to comment
Share on other sites

  • 3 weeks later...

How can you stop rounded corners on the main box - I tried this but it won't work:

$EzGUI = EzSkinGUICreate( "Fooy GUI", 450, 450, , 1, 0)

The last 0 (zero) should make it a square box.

Thanks anyway - its a super skin thing.

Edited by ToyleY
Link to comment
Share on other sites

  • 2 weeks later...

Some Feedback

1. Its not working if GUI has TABS ( The skin gets totally messed up )

2. the skin blocks the GUI name at the top of the GUI, making the name invisible

But yes Nice program.Thanx for the effort.

I noticed, that skin folder must always be present in my Scriptdir, even after I compile my script, I cant run it unless i have the skin folder in my exe dir.. This problem is now solved.Converter.au3 lets you to specify temp skin folder name & where should your exe write the skin temp folder only at first run. I recommend you save your temp folder to desktop to see how it works. If its has been written once already, your exe wont write it again. to make startup time faster, othervise lag is 1 sec.

EDIT: k Guess this is last mod to the converter script that should solve all conflicts if making more than 1 Skinned gui with this: It will ask for Temp skinpath & temp skin folder name each time you run converter.au3 . So all that left is to include #include <Filesin_binary.au3> in your own script+Compile it & you are done

Note:

note at the moment to use this following steps must be done:

1. After you have chosen your skin & buttons & Created your skin GUI via (#3 Create the script),put Converter.au3 in your EzSkin1 Folder, see below:

EzSkin -folder

EzSkin.au3

MyEzSkinDemo.au3

Converter.au3

Now run the Converter.au3 & it will look like this: ( this what happens,it takes all files from skin folder & converts them into a script & saves it as Filesin_binary.au3, so lather you can include this file in your own script )

EzSkin -folder

EzSkin.au3

MyEzSkinDemo.au3

Converter.au3

Filesin_binary.au3

1) there is no need to make it remove the temp skin folder when exiting GUI, if you will save all temp skins under same folder, for example-see below:

2) The line 698 in EzSkin.au3 is replaced automatically now when running Converter.au3

My Documents Folder
    Temp_skins Folder
        EzSkin_Green Folder
        EzSkin_lite  Folder
        EzSkin_blue  Folder etc.

Converter.au3 CODE:

#include<File.au3>
; Shows the filenames of all files in the current directory.
$_Skinpath = @ScriptDir & '\EzSkin\' ; original skin path should not be touched
$_include_FB = @ScriptDir & '\Filesin_binary.au3'
If FileExists('Filesin_binary.au3') Then FileDelete('Filesin_binary.au3')
   
;~ =================================================================================
;checks before $Temp_Skin_path_name can be written
;~ =================================================================================
If Not FileExists('EzSkin.au3') Then
    MsgBox(0, "ERROR:", 'Cant Find EzSkin.au3 in @Scriptdir...EXITING...')
    Exit
ElseIf Not FileExists('EzSkin') Then
    MsgBox(0, "ERROR:", 'Cant Find - EzSkin foder in @Scriptdir...EXITING...')
    Exit
EndIf
;~ =================================================================================
; Where Should We write the Temp skin folder?
;~ =================================================================================
MsgBox(0, "Message:", 'Please select where to save the temp skin folder.' & @CRLF & 'I strongly recommend saving all your skin folders under 1 spesific folder like'& @CRLF & @CRLF & 'C:\Temp\Temp_skinfolder\'& @CRLF &'EzSkin_Blue'& @CRLF &'EzSkin_Red etc...')

$browsefolder = FileSaveDialog('Choose the folder to save temp skin folder', @ScriptDir & "\", "Select temp Skin dir & Press SAVE(x.x)", 1 ,'Select temp Skin dir & Press SAVE')
If @error then Exit
$a = StringSplit($browsefolder,"\",0)
$Temp_Skin_savepath1 = StringReplace($browsefolder,$a[$a[0]], "")
$trim_savepath = StringTrimRight($Temp_Skin_savepath1,1) ; trim \
;~ =================================================================================
; ask for Unique Skin Folder name
;~ =================================================================================
$Prompt_Fr_TmpSkinDir_name = InputBox('Name the skinfolder', 'To avoid problems when making more than 1 skinned gui Plaease give your Gui Skin folder unique name', 'EzSkin_')
If @error then Exit
$Temp_Skin_path_name = $Prompt_Fr_TmpSkinDir_name
;~ =================================================================================
; REplace the tempskin dir line in EzSkin.au3
;~ =================================================================================
    Local $nArray ; read the file to array first
    If Not _FileReadToArray(@ScriptDir & '\EzSkin.au3', $nArray) Then MsgBox(0,'','cant read to array file:' & @CRLF & 'EzSkin.au3')
        ;~ FileDelete("test.txt")
        $file_open = FileOpen(@ScriptDir & '\EzSkin.au3', 2) ;2 = Write mode (erase previous contents)
                For $iCount = 1 To UBound($nArray) - 1
                If $iCount = UBound($nArray) - 1 Then ExitLoop   
;~   ;~ ---------------------------------------------------------------      
                    If Not StringInStr($nArray[$iCount],'Global $213A908B3713BB99') Then ; if found the text in the file we search for
                        FileWrite($file_open,$nArray[$iCount] & @CRLF)
                    Else
                        FileWrite($file_open,"Global $213A908B3713BB99 = " & "'" & $Temp_Skin_savepath1 & $Temp_Skin_path_name & "'" & @CRLF)
                    EndIf
                Next
                FileClose($file_open)
;~ =================================================================================
; Start converting files
;~ =================================================================================
$search_handle = FileFindFirstFile($_Skinpath & '*.*') 
If $search_handle = -1 Then
    MsgBox(0, "Error", "Cant Find the EzSkin folder")
    Exit
EndIf

While 1
    $file_found = FileFindNextFile($search_handle)
    If @error Then ExitLoop
   
    If StringInStr($file_found,'.bmp') Or StringInStr($file_found,'.dat') Then ; if find files we want to binarywrite..
        $S_Fn = StringSplit($file_found,'.')
        $S_replace = StringReplace($S_Fn[1],'-','_') ; replace - with _ in original filename or it will error
        $O_Fname = $S_replace
               
        $var = '$_' & $O_Fname

        $O_file_open = FileOpen($_Skinpath & $file_found, 16) ; open original file to be converted to binary
        $Save_File = FileOpen($_include_FB, 1) ; open file to save binary to
           
            Dim $firstline_ ;add create dir line to the Filesin_binary.au3 if its not there already
            If Not $firstline_ = 1 Then FileWrite($Save_File,"If Not FileExists(" & "'" & $Temp_Skin_savepath1 & $Temp_Skin_path_name & "') Then" & @CRLF & "DirCreate(" & "'" & $Temp_Skin_savepath1 & $Temp_Skin_path_name & "')"& @CRLF) ; write first line
            $firstline_ = 1
           
            FileWrite($Save_File, $var&'="0x"' & @CRLF) ; write first line
            While 1
                $data = FileRead($O_file_open, 30)
                If @error Then ExitLoop
                FileWrite($Save_File, $var&'&="' & StringTrimLeft($data,2) & '"' & @CRLF) ; saving binarydata
            WEnd
           
            ;write binary data to file
            ;adding a line at the end of  Filesin_binary.au3  ;path,Original filename,extension,binarydata to make files from binary
            FileWriteLine($Save_File, @CRLF  & @CRLF & "FileWrite(" & "'" & $Temp_Skin_savepath1 & $Temp_Skin_path_name & '\' & $file_found & "'" & ",Binary(" & $var & "))" & @CRLF & @CRLF )
EndIf
        FileClose($O_file_open)
        FileClose($Save_File)
WEnd
            $Save_File = FileOpen($_include_FB, 1) ; open file to save binary to
            FileWrite($Save_File,'Endif') ; write first line   
            FileClose($Save_File)

FileClose($search_handle)

MsgBox(4096, "Message:", 'Done',1)
Edited by goldenix
My Projects:[list][*]Guide - ytube step by step tut for reading memory with autoitscript + samples[*]WinHide - tool to show hide windows, Skinned With GDI+[*]Virtualdub batch job list maker - Batch Process all files with same settings[*]Exp calc - Exp calculator for online games[*]Automated Microsoft SQL Server 2000 installer[*]Image sorter helper for IrfanView - 1 click opens img & move ur mouse to close opened img[/list]
Link to comment
Share on other sites

Unique appraoch, I will place a link on page #1

However, with all that effort, I cant seem to understand how dificult this would be for you?

Some Feedback

1. Its not working if GUI has TABS ( The skin gets totally messed up )

2. the skin blocks the GUI name at the top of the GUI, making the name invisible

But yes Nice program.Thanx for the effort.

Posted Image

#include <GUIConstants.au3>
#include <EzSkin.au3>

$EzGUI = EzSkinGUICreate("MyEzSkinDemo",400,400)
$EzIcon = EzSkinIcon($EzGUI)

GUICtrlCreateLabel("MyEzSkinDemo", 50, 7, 110, 20)
GUICtrlSetBkColor( -1, $GUI_BKCOLOR_TRANSPARENT )
GUICtrlSetFont( -1, 10, 500)

$tab=GUICtrlCreateTab (50,50, 200,100)

$tab0=GUICtrlCreateTabitem ("tab-0")
GUICtrlCreateLabel ("label0", 80,130,50,20)
$tab0OK=GUICtrlCreateButton ("OK-0", 70,100,50,20)
$tab0input=GUICtrlCreateInput ("default", 130,100,70,20)

$tab1=GUICtrlCreateTabitem ( "tab-1")
GUICtrlCreateLabel ("label1", 80,130,50,20)
$tab1combo=GUICtrlCreateCombo ("", 70,100,60,120)
GUICtrlSetData(-1,"Trids|CyberSlug|Larry|Jon|Tylo", "Jon"); default Jon
$tab1OK=GUICtrlCreateButton ("OK1", 180,100,50,20)

$tab2=GUICtrlCreateTabitem ("tab-2")
GUICtrlSetState(-1,$GUI_SHOW); will be display first
GUICtrlCreateLabel ("label2", 80,130,50,20)
$tab2OK=GUICtrlCreateButton ("OK2", 140,100,50)

$tab3=GUICtrlCreateTabitem ("EzSkin Tabs")
GUICtrlCreateLabel ("What errors???", 80,130,90,20)


GUICtrlCreateTabitem (""); end tabitem definit

$Button = EzSkinButton("EzSkin Button", 150, 250, 100, 30) ;, $font_color)

GUISetState()

While 1
    EzSkinOver()
    $msg = GUIGetMsg()
    If $msg = $EzIcon[1] Then Exit
    If $msg = $EzIcon[2] Then GuiSetstate(@SW_MINIMIZE, $EzGUI)
    If $msg = $Button Then MsgBox(0x0,"Version", @AutoItVersion, 4)
    
    If $msg = $tab1OK Then MsgBox(0x0,"Test", "You pressed Button 1 in a tab", 4)
WEnd

Thanks for your effort!

8)

NEWHeader1.png

Link to comment
Share on other sites

However, with all that effort, I cant seem to understand how dificult this would be for you?

Looks like I did not explain myself clearly enough, Let me try it 1 more time:

1) gui Alignment gets screwed up

Assume user writes a script 1000 lines with many inputs,buttons,labels etc....

Now he wants to skin it,after he applies the skin, his gui will be messed up & he will have to redesign it & this might take ages....

Conclusion:

First skin your script & only then start adding labels,buttons etc....

2) the skin blocks the GUI name at the top of the GUI, making the name invisible

Actually at first I tried adding the name as a label, but it didnt work, ( possibly I used wrong coordinates )

Conclusion: if Gui has tabs, than the gui name label must be added to each TAB separately, other vise if you click next tab, the name will vanish. Also then name label must be inside specific GUICtrlCreateTabItem other vise it will look like on the picture see where the left arrow points.

3)TAB not skinned

As you may see the tab is not actually skinned, to see it with nice skin , change your Windows theme to Winxp theme for example.

Finally...we need a GUI script, that lets the user search the *.au3 file & replace the coordinates of the buttons,labels etc.

Posted Image

Edited by goldenix
My Projects:[list][*]Guide - ytube step by step tut for reading memory with autoitscript + samples[*]WinHide - tool to show hide windows, Skinned With GDI+[*]Virtualdub batch job list maker - Batch Process all files with same settings[*]Exp calc - Exp calculator for online games[*]Automated Microsoft SQL Server 2000 installer[*]Image sorter helper for IrfanView - 1 click opens img & move ur mouse to close opened img[/list]
Link to comment
Share on other sites

Be sure to use GUICtrlSetState($tab, $GUI_ONTOP)

Great Example by RazerM with EzSkin

#NoTrayIcon
#include <GUIConstants.au3>
;===============================================================================
;
; Program Name:        Unit Converter
; Description::        Converts Length, Area, Volume, Weight, and Temperature to different units
; Requirement(s):    None
; Author(s):        RazerM
;
;===============================================================================
;

Opt("GUIOnEventMode", 1)
;GUICreate("Imperial to Metric Converter", 440, 130)

#region ; Code generated by EzSkin_1-2-3, Created by Valuater
; For personal use only, All Rights Reserved
; Author of this code: Valuater
; Thank you big_daddy and Joscpe

#include <GUIConstants.au3>
#include <EzSkin.au3>

$EzGUI = EzSkinGUICreate ("Imperial to Metric Converter", 480, 190)
$EzIcon = EzSkinIcon ($EzGUI)
GUICtrlSetOnEvent($EzIcon[1], "Close")
GUICtrlSetOnEvent($EzIcon[2], "Mini")

#endregion

$tab = GUICtrlCreateTab(30, 40, 420, 110)
GUICtrlSetOnEvent(-1, "TabClicked")

GUICtrlCreateTabItem("Length")
GUICtrlCreateLabel("From:", 40, 65)
$LengthFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$LengthTo = GUICtrlCreateInput("", 290, 80, 150)
$LengthConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($LengthConvert, "ConvertLength")
$LengthFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Inches|Feet|Yards|Miles|Millimetres|Centimetres|Metres|Kilometres", "Inches")
$LengthToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Inches|Feet|Yards|Miles|Millimetres|Centimetres|Metres|Kilometres", "Millimetres")

GUICtrlCreateTabItem("Area")
GUICtrlCreateLabel("From:", 40, 65)
$AreaFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$AreaTo = GUICtrlCreateInput("", 290, 80, 150)
$AreaConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($AreaConvert, "ConvertArea")
$AreaFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Square Inches|Square Feet|Square Yards|Acres|Square Miles|Square Millimetres|Square Centimetres|Square Metres|Hectares|Square Kilometres", "Square Inches")
$AreaToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Square Inches|Square Feet|Square Yards|Acres|Square Miles|Square Millimetres|Square Centimetres|Square Metres|Hectares|Square Kilometres", "Square Millimetres")

GUICtrlCreateTabItem("Volume")
GUICtrlCreateLabel("From:", 40, 65)
$VolumeFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$VolumeTo = GUICtrlCreateInput("", 290, 80, 150)
$VolumeConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($VolumeConvert, "ConvertVolume")
$VolumeFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Cubic Inches|Cubic Feet|Fluid Ounces|Pints|Gallons|US Fluid Ounces|US Pints|US Gallons|Cubic Centimetres|Cubic Decimetres|Cubic Metres|Litres|Hectolitres", "Cubic Inches")
$VolumeToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Cubic Inches|Cubic Feet|Fluid Ounces|Pints|Gallons|US Fluid Ounces|US Pints|US Gallons|Cubic Centimetres|Cubic Decimetres|Cubic Metres|Litres|Hectolitres", "Cubic Centimetres")

GUICtrlCreateTabItem("Weight")
GUICtrlCreateLabel("From:", 40, 65)
$WeightFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$WeightTo = GUICtrlCreateInput("", 290, 80, 150)
$WeightConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($WeightConvert, "ConvertWeight")
$WeightFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Ounces|Pounds|Stone|Milligrams|Grams|Kilograms", "Ounces")
$WeightToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Ounces|Pounds|Stone|Milligrams|Grams|Kilograms", "Milligrams")

GUICtrlCreateTabItem("Temperature")
GUICtrlCreateLabel("From:", 40, 65)
$TempFrom = GUICtrlCreateInput("", 40, 80, 150)
GUICtrlCreateLabel("To:", 290, 65)
$TempTo = GUICtrlCreateInput("", 290, 80, 150)
$TempConvert = EzSkinButton ("Convert", 200, 80, 80, 25)
GUICtrlSetOnEvent($TempConvert, "ConvertTemp")
$TempFromUnits = GUICtrlCreateCombo("", 40, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Celsius|Fahrenheit|Kelvin", "Celsius")
$TempToUnits = GUICtrlCreateCombo("", 290, 110, 150, 200, $CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "Celsius|Fahrenheit|Kelvin", "Fahrenheit")

GUICtrlCreateTabItem(" EzSkin!!!  &&  Converter ")
$TempSkin = GUICtrlCreateLabel("> More EzSkin Designs are located here <", 60, 90, 375, 30)
GUICtrlSetColor(-1, 0xff)
GUICtrlSetFont(-1, 14, 500, 6)
GUICtrlSetOnEvent(-1, "Get_Skins")
GUICtrlCreateTabItem("")

GUICtrlSetState($LengthConvert, $GUI_DEFBUTTON)

GUISetState()
GUISetOnEvent($GUI_EVENT_CLOSE, "Close")

GUICtrlSetState($tab, $GUI_ONTOP)

While 1
    EzSkinOver ($EzGUI)
    Sleep(20)
WEnd

Func ConvertTemp()
    $vFrom = Execute(GUICtrlRead($TempFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[3][2] = [["Kelvin", ")*1"], ["Fahrenheit", "+459.67)*5/9"], ["Celsius", "+273.15)"]]
    Local $avToUnits[3][2] = [["Kelvin", ")*1"], ["Fahrenheit", "*9/5-459.67)"], ["Celsius", "-273.15)"]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($TempFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom = Execute("(" & $vFrom & $avUnits[$iUnit][1])
        EndIf
    Next
    For $iUnit = 0 To UBound($avToUnits) - 1
        If GUICtrlRead($TempToUnits) = $avToUnits[$iUnit][0] Then
            $vTo = Execute("(" & $vFrom & $avToUnits[$iUnit][1])
        EndIf
    Next
    GUICtrlSetData($TempTo, $vTo)
EndFunc   ;==>ConvertTemp

Func ConvertWeight()
    $vFrom = Execute(GUICtrlRead($WeightFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[6][2] = [["Ounces", 1], ["Pounds", 16], ["Stone", 224], ["Milligrams", 3.52739619 * 10 ^ - 5], ["Grams", 0.0352739619], ["Kilograms", 35.2739619]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($WeightFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom *= $avUnits[$iUnit][1]
        EndIf
    Next
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($WeightToUnits) = $avUnits[$iUnit][0] Then
            $vTo = $vFrom / $avUnits[$iUnit][1]
        EndIf
    Next
    GUICtrlSetData($WeightTo, $vTo)
EndFunc   ;==>ConvertWeight

Func ConvertVolume()
    $vFrom = Execute(GUICtrlRead($VolumeFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[13][2] = [["Cubic Inches", 1], ["Cubic Feet", 1728], ["Fluid Ounces", 1.73387217], ["Pints", 34.6774434], ["Gallons", 277.419547], ["US Fluid Ounces", 1.80468751 ], ["US Pints", 28.8750001], ["US Gallons", 231.000001], ["Cubic Centimetres", 0.0610237441], ["Cubic Decimetres", 61.0237441], ["Cubic Metres", 61023.7441], ["Litres", 61.0237441], ["Hectolitres", 6102.37441]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($VolumeFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom *= $avUnits[$iUnit][1]
        EndIf
    Next
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($VolumeToUnits) = $avUnits[$iUnit][0] Then
            $vTo = $vFrom / $avUnits[$iUnit][1]
        EndIf
    Next
    GUICtrlSetData($VolumeTo, $vTo)
EndFunc   ;==>ConvertVolume

Func ConvertArea()
    $vFrom = Execute(GUICtrlRead($AreaFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[10][2] = [["Square Inches", 1], ["Square Feet", 144], ["Square Yards", 1296], ["Acres", 6272640], ["Square Miles", 4014489600], ["Square Millimetres", 0.0015500031], ["Square Centimetres", 0.15500031], ["Square Metres", 1550.0031], ["Hectares", 15500031], ["Square Kilometres", 1.5500031 * 10 ^ 9]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($AreaFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom *= $avUnits[$iUnit][1]
        EndIf
    Next
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($AreaToUnits) = $avUnits[$iUnit][0] Then
            $vTo = $vFrom / $avUnits[$iUnit][1]
        EndIf
    Next
    GUICtrlSetData($AreaTo, $vTo)
EndFunc   ;==>ConvertArea

Func ConvertLength()
    $vFrom = Execute(GUICtrlRead($LengthFrom))
    If Not IsNumber(Number($vFrom)) Then Return SetError(1, 0, 0)
    Local $avUnits[8][2] = [["Inches", 1], ["Feet", 12], ["Yards", 36], ["Miles", 63360], ["Millimetres", 0.0393700787], ["Centimetres", 0.393700787], ["Metres", 39.3700787], ["Kilometres", 39370.0787]]
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($LengthFromUnits) = $avUnits[$iUnit][0] Then
            $vFrom *= $avUnits[$iUnit][1]
        EndIf
    Next
    For $iUnit = 0 To UBound($avUnits) - 1
        If GUICtrlRead($LengthToUnits) = $avUnits[$iUnit][0] Then
            $vTo = $vFrom / $avUnits[$iUnit][1]
        EndIf
    Next
    GUICtrlSetData($LengthTo, $vTo)
EndFunc   ;==>ConvertLength

Func TabClicked()
    Switch GUICtrlRead($tab)
        Case 0 ;Length Tab is visible
            GUICtrlSetState($LengthConvert, $GUI_DEFBUTTON)
        Case 1 ;Area Tab is visible
            GUICtrlSetState($AreaConvert, $GUI_DEFBUTTON)
        Case 2 ;Volume Tab is visible
            GUICtrlSetState($VolumeConvert, $GUI_DEFBUTTON)
        Case 3 ;Weight Tab is visible
            GUICtrlSetState($WeightConvert, $GUI_DEFBUTTON)
        Case 4 ;Temperature Tab is visible
            GUICtrlSetState($TempConvert, $GUI_DEFBUTTON)
    EndSwitch
EndFunc   ;==>TabClicked

Func Get_Skins()
    ShellExecute("http://www.autoitscript.com/forum/index.php?showtopic=41319")
EndFunc   ;==>Get_Skins

Func Close()
    Exit
EndFunc   ;==>Close

Func Mini()
    GUISetState(@SW_MINIMIZE)
EndFunc   ;==>Mini

8)

NEWHeader1.png

Link to comment
Share on other sites

  • 3 months later...
  • 1 month later...

As I have been asked numerous times..

The EzSkin Location is hard coded, however, this may changed very easily.

just look at line # 698 you will see... (or just search for @ScriptDir)

Global $213A908B3713BB99 = @ScriptDir & $213AE08D5A13BB99

You may change this @ScriptDir to any folder/location you wish.

You should not make any other changes.. just the folder location

8)

NEWHeader1.png

Link to comment
Share on other sites

  • 1 month later...

How exactly do I use this? I just created by 1st GUI and EzSkin doesn't have so much as a readme.txt! After poking around for several minutes, I ran across EzSkinConvert.au3, but I can't figure out how to compile a script so that it contains the skin of my choice.

Edited by robinsiebler
Link to comment
Share on other sites

How exactly do I use this? I just created by 1st GUI and EzSkin doesn't have so much as a readme.txt! After poking around for several minutes, I ran across EzSkinConvert.au3, but I can't figure out how to compile a script so that it contains the skin of my choice.

EzSkin.exe is designed to build a skin with picture buttons, All your choice, in three easy steps. This should be done first, however, if you just enlarge your original script by 100 wide and 100 tall then move all controls to the right 50 and down 50 it will work fine... there is a help file with XSkin

Use FileInstall() to include the skin and data you need

EzSkinConvert.au3 is not supported by me, thats a take-off of easy skin and a little more complicated.

8)

Edited by Valuater

NEWHeader1.png

Link to comment
Share on other sites

EzSkin.exe is designed to build a skin with picture buttons, All your choice, in three easy steps. This should be done first, however, if you just enlarge your original script by 100 wide and 100 tall then move all controls to the right 50 and down 50 it will work fine... there is a help file with XSkin

Use FileInstall() to include the skin and data you need

EzSkinConvert.au3 is not supported by me, thats a take-off of easy skin and a little more complicated.

8)

I added these lines near the beginning of my script:

DirCreate(".\Skins\Velox")

FileInstall("c:\Program Files\AutoIt3\EzSkin\Skins\Velox\0.bmp", ".\Skins\Velox")

...

FileInstall("C:\scripts\autoit3\ToolsGUI\EzSkin.ini", ".")

When I run the compiled script, the \Skins\Velox dir is empty and the EzSkin.ini is the default one that refers to the Wood Skin. What am I doing wrong? Also, who wrote EzSkinConvert.au3? Or EzSkinEmbedded.au3 and how do I use that?

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...