Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 07/14/2023 in Posts

  1. I've been using AutoIt for a couple of decades now, and created hundreds of programs, and my knowledge of C and derivatives could be written on a Napkin, and in all reality has never served me in my use of AutoIt. That said, I have of course benefited from the understanding of C etc by those who have developed and maintain AutoIt. I mostly came to AutoIt via VB 4, 5 & 6, especially VBA, where I would have created (and still do) lots of VBA macros. I'd dabbled with some C variants etc, but was quite turned off by them, they not matching how my mind works or wants to work. I'd class AutoIt as a bit like VB, but with a lot of the nonsense missing. To this day, despite how experienced I am with VBA, it still regularly gives me grief ... that rarely occurs with AutoIt ... all to do, in my view, with the mentality behind them. But then I am totally self taught, in the monkey-see monkey-do style of coding, with the ability to analyze enough. I am not well versed on theory and concepts, other than what I have picked up on-the-fly. Jon & the AutoIt Team, past & present, have liberated many folk like myself, for which I will eternally be grateful. In my view, AutoIt is the best language for the average person on the street to use, bar none. It is simple enough and plain speaking enough, with a superb Help file, to introduce many to programming, without the requirement to be nerdy etc. Many of course then move onto other languages, but often retain AutoIt in their toolbox.
    3 points
  2. Ahem! The very first versions of C++ were just a C pre-processor !
    3 points
  3. Nah, my default code is better than his default code. I won't give him mine. I'm not sure what he is doing wrong and why all red flags are on, I just hope his window name doesn't have a title such as "My Default Trojan - It's just a test bro" or something like that. PS: @argumentum with such experience, I should hire you to translate me all strange requests from this forum
    2 points
  4. "I married 3 times, divorced 3 times, marriage is doom to failure." Well, that is 1 experience. Go figure what made the marriages fail ( it was me ), I have no clue, I'm the best there is. If he has a claim, he has a claim. In his view is true and ... that's his experience. Let's do something about it. Zip up your code, give it to him, he'd translate it to his native langue and/or use his compiler and see if the resultant binary is better accepted by the AVs, or not. Lets debug it via a scientific method. Replication
    2 points
  5. But that's not true as well. I compiled a simple app in C++ and all reports has been ok except a no name AV software, which I had to google to get some info about and it was some shitty AI probably in training. So it's not just a language barrier, his claims are wrong.
    1 point
  6. t0nZ

    AutoIt Snippets

    Very interesting, I think we can add also national holidays to the count, excluding these days. To obtain a list of updated national holidays there are some services online, but for a quick test I asked chatgpt: 20230101,Capodanno 20230106,Epifania 20230409,Domenica di Pasqua 20230416,Lunedì dell'Angelo 20230425,Festa della Liberazione 20230501,Festa dei Lavoratori 20230602,Festa della Repubblica 20230815,Ferragosto 20231101,Ognissanti 20231208,Immacolata Concezione 20231225,Natale I am thinking to work on this...
    1 point
  7. Yeah yeah. I do seem to recall having a quick look at it a while back, like I usually do with new languages ... just to see if anyone is as smart as Jon ... not found any yet ... plenty of clever folk though ... nerdies.
    1 point
  8. Goodness !, ... different languages, cultures and thought patterns !. All he is saying, ( not very well in English I must say ), is that even a default "Hello world" ( in C, C++, AutoIt, MyOwnLanguage ), gets a "no go" from the virus detectors. That's that in regards to viruses. The C++ is in regards to structs, pointers and DLL handling. And that is that in regards to the "C++" thing. Good chat
    1 point
  9. Hmm, using Ternary it can get even smaller... Func _WM_NCHITTEST($hWnd, $uMsg, $wParam, $lParam) Local $Cur = GUIGetCursorInfo($hWnd) If ($aCurInfo[4] > 0) Then Return If Not (WinGetState($hWnd) = 47) And ($Cur[4] = 0) Then Local $Cursor[9] = [2,13,13,11,12,10,11,10,12], $CurInf, $Pos = WinGetPos($hWnd) $CurInf=($Cur[0]>$Pos[2]-6?2:$Cur[0]<6?1:0)+($Cur[1]>$Pos[3]-6?6:$Cur[1]<6?3:0) GUISetCursor($Cursor[$CurInf], 1) Return $CurInf + 9 EndIf Return 'GUI_RUNDEFMSG' EndFunc ;==>INTERNAL_WM_NCHITTEST From 49 lines to 11 lines, Ternary Rocks! Sorry for OT, but the thread was already answered by Andreik and argumentum.
    1 point
  10. That's indeed all I need, a C++ tutorial. Now all my code will be default. I really suspect you being a troll.
    1 point
  11. I think C++ is a language of importance and value among programming languages... I do not disagree with you on that... Anyway, I also had the idea of doing a programming language compiler. I think the most difficult link in creating a programming language is processing algorithms and checking for errors through them.. In my opinion, this process... is very complex.. requires focus.... long continuous work... and performance in formulating the code... accurate and advanced.
    1 point
  12. All this... If Not (WinGetState($hWnd) = 47) Then If ($aCurInfo[4] = 0) Then Local $Return_HT = 2, $Set_Cursor = 2 Switch $CurSorInfo Case 1 $Set_Cursor = 13 $Return_HT = 10 Case 2 $Set_Cursor = 13 $Return_HT = 11 Case 3 $Set_Cursor = 11 $Return_HT = 12 Case 4 $Set_Cursor = 12 $Return_HT = 13 Case 5 $Set_Cursor = 10 $Return_HT = 14 Case 6 $Set_Cursor = 11 $Return_HT = 15 Case 7 $Set_Cursor = 10 $Return_HT = 16 Case 8 $Set_Cursor = 12 $Return_HT = 17 EndSwitch GUISetCursor($Set_Cursor, 1) If Not ($Return_HT = 2) Then Return $Return_HT EndIf EndIf can be written as... If Not (WinGetState($hWnd) = 47) And ($aCurInfo[4] = 0) Then Local $Set_Cursor[9] = [2, 13, 13, 11, 12, 10, 11, 10, 12] GUISetCursor($Set_Cursor[$CursorInfo], 1) Return $CursorInfo + 9 EndIf So all in all... #include <WindowsConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> HotKeySet("{ESC}", "On_Exit") $hGUI = GUICreate("Y", 400, 150, -1, -1, $WS_POPUP) GUISetBkColor(0x414141) GUICtrlCreateInput("", 10, 10, 50, 25) GUICtrlSetCursor(-1, 5) ; <------------ here =) GUISetState() GUIRegisterMsg(0x0084, "_WM_NCHITTEST") While 1 Sleep(10) WEnd Func _WM_NCHITTEST($hWnd, $uMsg, $wParam, $lParam) Local $iSide = 0, $iTopBot = 0, $CurSorInfo, $i_marginResize = 6 Local $aWinPos = WinGetPos($hWnd) Local $aCurInfo = GUIGetCursorInfo($hWnd) If Not @error Then If ($aCurInfo[4] > 0) Then Return ;Check if Mouse is over Border, Margin = 6 If $aCurInfo[0] < $i_marginResize Then $iSide = 1 If $aCurInfo[0] > $aWinPos[2] - $i_marginResize Then $iSide = 2 If $aCurInfo[1] < $i_marginResize Then $iTopBot = 3 If $aCurInfo[1] > $aWinPos[3] - $i_marginResize Then $iTopBot = 6 $CurSorInfo = $iSide + $iTopBot Else $CurSorInfo = 0 EndIf If Not (WinGetState($hWnd) = 47) And ($aCurInfo[4] = 0) Then Local $Set_Cursor[9] = [2, 13, 13, 11, 12, 10, 11, 10, 12] GUISetCursor($Set_Cursor[$CursorInfo], 1) Return $CursorInfo + 9 EndIf Return 'GUI_RUNDEFMSG' EndFunc ;==>INTERNAL_WM_NCHITTEST Func On_Exit() Exit EndFunc ;==>On_Exit
    1 point
  13. MichaelCrawley

    Moving Screens

    Oh my, I did not even see this I really apreciate the work you put into this. This is awesome, If you don't mind I am going to save this reuse it in other areas because I certain I will use it. I am going to see if I can break it down into smaller componets to ame sure I understand it.
    1 point
  14. #include <WindowsConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> HotKeySet("{ESC}", "On_Exit") $hGUI = GUICreate("Y", 400, 150, -1, -1, $WS_POPUP) GUISetBkColor(0x414141) GUICtrlCreateInput("", 10, 10, 50, 25) GUICtrlSetCursor(-1, 5) ; <------------ here =) GUISetState() GUIRegisterMsg(0x0084, "_WM_NCHITTEST") While 1 Sleep(10) WEnd Func _WM_NCHITTEST($hWnd, $uMsg, $wParam, $lParam) Local $iSide = 0, $iTopBot = 0, $CurSorInfo, $i_marginResize = 6 Local $aWinPos = WinGetPos($hWnd) Local $aCurInfo = GUIGetCursorInfo($hWnd) If Not @error Then If ($aCurInfo[4] > 0) Then Return ;Check if Mouse is over Border, Margin = 6 If $aCurInfo[0] < $i_marginResize Then $iSide = 1 If $aCurInfo[0] > $aWinPos[2] - $i_marginResize Then $iSide = 2 If $aCurInfo[1] < $i_marginResize Then $iTopBot = 3 If $aCurInfo[1] > $aWinPos[3] - $i_marginResize Then $iTopBot = 6 $CurSorInfo = $iSide + $iTopBot Else $CurSorInfo = 0 EndIf If Not (WinGetState($hWnd) = 47) Then If ($aCurInfo[4] = 0) Then Local $Return_HT = 2, $Set_Cursor = 2 Switch $CurSorInfo Case 1 $Set_Cursor = 13 $Return_HT = 10 Case 2 $Set_Cursor = 13 $Return_HT = 11 Case 3 $Set_Cursor = 11 $Return_HT = 12 Case 4 $Set_Cursor = 12 $Return_HT = 13 Case 5 $Set_Cursor = 10 $Return_HT = 14 Case 6 $Set_Cursor = 11 $Return_HT = 15 Case 7 $Set_Cursor = 10 $Return_HT = 16 Case 8 $Set_Cursor = 12 $Return_HT = 17 EndSwitch GUISetCursor($Set_Cursor, 1) If Not ($Return_HT = 2) Then Return $Return_HT EndIf EndIf Return 'GUI_RUNDEFMSG' EndFunc ;==>INTERNAL_WM_NCHITTEST Func On_Exit() Exit EndFunc ;==>On_Exit
    1 point
  15. I am not sure what do you want to do but instead of GUISetCursor(), which set the cursor for the entire window, use GUICtrlSetCursor() to set a specific cursor to your input control.
    1 point
  16. @n3wbie The $oParams parameter needs to be an object. You probably need to do something like this -- Local $aURLs = ["google.com", "facebook.com"] Local $oParams = Json_ObjCreate() Json_ObjPut($oParams, 'urls', $aURLs) _WD_CDPExecuteCommand($sSession, "Network.setBlockedURLs", $oParams)
    1 point
×
×
  • Create New...