Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 12/11/2015 in all areas

  1. iamtheky

    Idea for arrays

    just use a map, then you can call the indices whatever you want?
    1 point
  2. argumentum, Thanks for uploading it. Adam
    1 point
  3. Jefrey

    i18n library

    I needed to create a simple i18n library for an open-source project I've worked on last week. So I made this simple and easy to use. When translating, you have two options: the first one is to use a global file on the following format: [language_code] text_id=Translation text_with_format=Number: %.2f text_with_parameter=Hi %s [another_language_code] text_id=Tradução ... The second option is to separate every translation into files named language_code.lng in a folder of your choice. Note that every file on this folder will have the following format: [language_code] text_id=Translation text_with_format=Number: %.2f text_with_parameter=Hi %s The language code can be ISO 639-1 (2 chars, like "en", "pt", "es") or culture code (including the country, like "en-US", "pt-BR", "es-ES"). You can use both these formats on the same file/project without any problem. Finally, use the _() function to get your translation text. It accepts the following syntax: _($sText_id [, $sPar1 [, $sParn ] ] ) The parameters are optional, but the maximum number of parameters is 32. If you need more than 32 parameters (sure?), please consider splitting your string into multiple ones. Note that everything is explained on the Example.au3 (see online) and Example.lng (see online) file. Interesting note (source): Download: AutoIt Files Fork me on Github
    1 point
  4. iamtheky

    Idea for arrays

    Can you describe that in code? The wording is tough to decipher.
    1 point
  5. water

    Need Help

    BTW: If you should decide to open a new thread an whatever subject please give it a meaningful title. So people know what it is all about. Everyone on this forum is looking for help
    1 point
  6. Jos

    Need Help

    Me neither ... so last chance: Be clear what you are doing or this thread will auto-magically lock itself. Jos
    1 point
  7. Started to do some debugging and one thing that is wrong is that you are test the handle "Switch $Combo1"in stead of "Switch $Choice". Here is how you can do debugging in SciTE (Full version) with Al+D: #include <ButtonConstants.au3> #include <ComboConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 623, 285, 192, 114) $Button1 = GUICtrlCreateButton("Randomize Button", 192, 184, 185, 73) $Input1 = GUICtrlCreateInput("0", 24, 40, 121, 21) $Input2 = GUICtrlCreateInput("0", 24, 72, 121, 21) $Combo1 = GUICtrlCreateCombo("", 24, 112, 145, 25, BitOR($CBS_DROPDOWN, $CBS_AUTOHSCROLL)) GUICtrlSetData($Combo1, "1|2|3|4|5") $Input3 = GUICtrlCreateInput("0", 400, 40, 121, 21) $Input4 = GUICtrlCreateInput("0", 400, 72, 121, 21) $Combo2 = GUICtrlCreateCombo("", 400, 112, 145, 25, BitOR($CBS_DROPDOWN, $CBS_AUTOHSCROLL)) GUICtrlSetData($Combo2, "A|B|C|D|E") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### Global $Max = 0 Global $Max1 = 0 While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Combo1 Global $Choice = GUICtrlRead($Combo1) ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $Choice = ' & $Choice & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console Switch $Choice Case "1" $Max=10 Case "2" $Max=20 ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $Max = ' & $Max & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console Case "3" $Max=30 Case "4" GUICtrlSetData($Max, 40) Case "5" GUICtrlSetData($Max, 50) EndSwitch Case $Combo2 Global $Max1 = GUICtrlRead($Combo2) Switch $Max1 Case "A" Or "B" Or "C" GUICtrlSetData($Max1, 60) Case Else GUICtrlSetData($Max1, 100) EndSwitch Case $Button1 Randomize() EndSwitch WEnd Func Randomize() $Input1 = Random(0, $Max, 1) ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $Input1 = ' & $Input1 & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console $Input2 = Random(0, $Max, 1) ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $Input2 = ' & $Input2 & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console $Input3 = Random(0, $Max1, 1) ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $Input3 = ' & $Input3 & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console $Input4 = Random(0, $Max1, 1) ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $Input4 = ' & $Input4 & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console EndFunc ;==>RandomizeJust to get you going. Jos
    1 point
    I like it,a'm just started with autoit,so a get al de information a can get.This a good beginning usefull i find. Thanks Jfish
    1 point
×
×
  • Create New...