Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 08/11/2017 in all areas

  1. Working example _QPDF_AddStandardFont_Lite($oQP, 13) ; $__eQPDF_StandardFontID_ZapfDingbats) ; 13 ;~ _QPDF_SelectFont_Lite($oQP, $__eQPDF_StandardFontID_ZapfDingbats) $oQP.SetTextSize(20) ; _QPDF_DrawText_Lite($oQP, 186, 187, "$") _QPDF_AddStandardFont_Lite($oQP, 0) ;~ _QPDF_SelectFont_Lite($oQP, $__eQPDF_StandardFontID_CourierOblique) $oQP.SetTextSize(20) ; $oQP.DrawTextBox(20, 180, 176, 40, ". . . . . . . . . . . . . . . . . . . ", 1) $NewImage = @ScriptDir & "\mypic.bmp" $oQP.AddImageFromFile($NewImage, 0) $oQP.DrawImage(20, 200, 30, 30) ; left, top, wide, height You should see a line of dots with a pair of scissors at the right margin You must supply your own .bmp Note this is with v0.8 Skysnake
    1 point
  2. 1 point
  3. Then now is the perfect point in time to learn something new The help file explains how to get the handle of a control.
    1 point
  4. Compile it as an exe, and then call that exe with parameters...do logic on that to call functions.
    1 point
  5. Hm... I am still not quite sure what is the problem. You want window to be closed without pressing red cross? Or you just need corrdinates for red cross but not interact with it? Well, this gives you a position of the red cross: $WinPos = WinGetPos ( "Untitled" ) Onscreen coordinates for the red cross are $WinPos[0] + $WinPos[2] - 15 , $WinPos[1] + 10 You can make a While 1 loop to make script get coordinates indefinite times if the window is literally moving around constantly. Also, have you tried Controlsend ALT+F4 to window you want to close if that is your goal?
    1 point
  6. timmalos

    [UDF] CasparCG AMCP 2.1

    Hello all. In case this is interesting few of you, I share my AMCP 2.1 protocol UDF in AutoIT. This protocol is used by CasparCG server, which is a Windows and Linux software used to play out professional graphics, audio and video to multiple outputs as a layerbased real-time compositor. It has been in 24/7 broadcast production since 2006. It's free and opensource. The UDF I share allows communication between an AutoIt based client and the CasparCG, based on following documentation : http://casparcg.com/wiki/CasparCG_2.1_AMCP_Protocol If you want more details on CasparCG : official WebSite or have a look to this video I'm currently building a full Client based on AutoIt, with many features like drag-and-drop layers, but sadly I can't share it right now, might come later. Don't hesitate to ask questions if you have any or need a basic example. The only requirement for this UDF is the other Event-driven TCP UDF by Kip AMCP_shared.au3 TCP.au3
    1 point
  7. Element 4 of each array row contains the contact object. The possible properties you can retrieve can be found here: https://msdn.microsoft.com/de-de/library/ff867603.aspx Example: $aResult[1][4].LastName returns the lastname of the first contact.
    1 point
  8. Jibberish, An alternative approach. Nota Bene, for this to work the controls must be defined consecutively. This is handy for a large number of controls that can change... ; *** Start added by AutoIt3Wrapper *** #include <GUIConstantsEx.au3> ; *** End added by AutoIt3Wrapper *** #include <array.au3> ; Includes, etc #AutoIt3Wrapper_Add_Constants=n Local $aOptionsArray[3] ; lots of other code Local $gui010 = GUICreate('Test') Local $bSelect1 = GUICtrlCreateCheckbox('#1', 10, 10, 100, 20) Local $bSelect2 = GUICtrlCreateCheckbox('#2', 10, 30, 100, 20) Local $bSelect3 = GUICtrlCreateCheckbox('#3', 10, 50, 100, 20) GUISetState() While 1 Switch GUIGetMsg() Case $gui_event_close Exit Case $bSelect1 To $bSelect3 _CheckboxesAndRadioButtons() _ArrayDisplay($aOptionsArray) EndSwitch WEnd Func _CheckboxesAndRadioButtons() ; Create Checkboxes and Radio Buttons and read the results ; all variables in this Function were assigned either at the top of the script or in the function. ; Radio Buttons to Array ; $aOptions[0] = $bTestSelectForever ; $aOptions[1] = $bTestSelect3Times ; $aOptions[2] = $bTestSelectOnce For $i = 0 To UBound($aOptionsArray) - 1 $aOptionsArray[$i] = (GUICtrlRead(Eval('bSelect' & $i + 1)) = $gui_checked) ? 'True' : 'False' Next EndFunc ;==>_CheckboxesAndRadioButtons Also, it might be helpful for you to read (re-read) the helpfile sections concerning "scope" and function calls (byref vs. value). kylomas
    1 point
  9. Hi Jibberish, First I took your Start Button and wrapped an If Else Endif statement into it, to read the results of the Radio button. I've also cleaned your script up. Took away your function. No need to wrap it in a func. #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> $hGUI = GUICreate("SGX4CP Tests", 300, 300, 192, 124) $bSelect1 = GUICtrlCreateRadio("Select 1", 10, 160) $bSelect2 = GUICtrlCreateRadio("Select 2", 10, 190) $bSelect3 = GUICtrlCreateRadio("Select 3", 10, 220) $idClose = GUICtrlCreateButton("Start", 120, 250) GUISetState(@SW_SHOW) ; Set TestSelectForever as the default radio button GUICtrlSetState($bSelect1, $GUI_CHECKED) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $bSelect1 MsgBox(0, "", "Select1") Case $bSelect2 MsgBox(0, "", "Select2") Case $bSelect3 MsgBox(0, "", "Select3") Case $idClose $bSelect1 = GUICtrlRead($bSelect1) $bSelect2 = GUICtrlRead($bSelect2) $bSelect3 = GUICtrlRead($bSelect3) If $bSelect1 = 1 Then $Radio1 = String("checked") Else $Radio1 = String("not checked") EndIf If $bSelect2 = 1 Then $Radio2 = String("checked") Else $Radio2 = String("not checked") EndIf If $bSelect3 = 1 Then $Radio3 = String("checked") Else $Radio3 = String("not checked") EndIf MsgBox(0, "Results", "Select1 is " & $Radio1 & ". Select2 is " & $Radio2 & ". Select3 is " & $Radio3 & ".") ExitLoop EndSwitch WEnd
    1 point
  10. Try this HotKeySet("^c", "Func1")
    1 point
×
×
  • Create New...