Jump to content

TheDcoder

Active Members
  • Posts

    7,103
  • Joined

  • Days Won

    88

Everything posted by TheDcoder

  1. What am I seeing here , Using AutoItX COM Library in VB.NET instead of using VB.NET's own abilities ?
  2. @UEZ Am I doing something wrong?: ; Includes #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <GuiButton.au3> #include <GuiListView.au3> #include <StaticConstants.au3> #include <WinAPI.au3> ; Main GUI Global $hGUI = GUICreate("GUI", 528, 287) Global $idStatusBar = GUICtrlCreateProgress(113,61,325,20) Global $idStatusText = GUICtrlCreateLabel("Test",113,64,325,16,$SS_CENTER) GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT) $hLayerGUI = GUICreate("", 20, 17, (113 + 325 - 20) / 2, 61, $WS_POPUP, BitOR($WS_EX_LAYERED, $WS_EX_TRANSPARENT, $WS_EX_MDICHILD), $hGUI) GUISetBkColor(0x989898, $hLayerGUI) _WinAPI_SetLayeredWindowAttributes($hLayerGUI, 0x989898) GUICtrlCreateButton("Button",221,83,100,26) GUISetState(@SW_SHOW, $hGUI) For $i = 0 To 100 Step 10 SetStatus($i) Sleep(250) Next While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Func SetStatus($fStatus = 0, $sStatus = Default) If Not $sStatus = Default Then GUICtrlSetData($idStatusText, $sStatus) GUICtrlSetData($idStatusBar, $fStatus) EndFunc ;==>SetStatusWhere is the button & the status label? TD
  3. Please watch Morthwart's great AutoIt tutorials! TD P.S I learned AutoIt using these videos
  4. @Jos That way its much easier for you to start coding soon (earlier?) @water You are not going to see a huge script made by me anytime soon! TD
  5. Also keep in mind that empty arrays take space too... Also develop a specific kind of programming pattern in your program if you are making a huge program, note that you don't have to plan your programming pattern first-hand, you will have to do it when you start coding your script, that ways its much easier. These are things which I follow when I code a big code hungry script. TD
  6. @UEZ Thanks , So this is the simplified formula: ($iPosX + $iWidth - $iWidthOfChild) / 2 = $iPosXOfChild TD
  7. @UEZ Can you explain the bold part: Or give me the formula for calculating left & top TD
  8. @guinness Oh, I have decided the name for it, its Binary Steganography
  9. @Jos Yeah, I know but I was wondering how the archive is still valid ...
  10. @Manadar That sounds more like cryptology... I am sure the term start with "Binary". Binary Combination maybe ?
  11. Hello Experts , I did an interesting experiment today: What I did is make a text.txt file & archived it in a text.7z file... Then I combined those two files (text.txt & text.7z) using this command: copy /b text.txt+text.7z text.binIt made a file called text.bin... I tried to open it using 7z and guess what? IT WORKED! Q. What is this process called? I need some more intel on this process... That would help me create my own file format Thanks in Advance, TD P.S Do you ask why did I post it in dev chat? Because the GH & S section is only for AutoIt
  12. I found some solutions, they use GDI+ or some complicated DllCalls... This is the best solution I found but it removes that fancy animation . I am still looking for a solution which does this without removing the animation, TD P.S Forum search sucks! Instead use site:autoitscript.com/forum <Insert your problem here> in google.
  13. Hello , I am using this code to make a nice progress bar which also tells what is going on: #include <GUIConstantsEx.au3> #include <ProgressConstants.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= GUICreate("GUI", 294, 69, 192, 124) $idProgressBar = GUICtrlCreateProgress(8, 24, 278, 17) $idLabel = GUICtrlCreateLabel("0", 8, 24, 276, 17, $SS_CENTER) GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### For $i = 0 To 10 GUICtrlSetData($idProgressBar, CalcPercent($i, 10)) GUICtrlSetData($idLabel, $i) Sleep(1000) Next While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Func CalcPercent($iPartDone, $iTotal, $iRoundToDecimalPlace = 1) Return Round(($iPartDone / $iTotal) * 100, $iRoundToDecimalPlace) EndFuncBut the label hides behind the progress bar when I update it , How can I prevent this? Thanks in Advance, TD
  14. @JohnOne
  15. @JLogan3o13 Debate: How my example differs from ProgressSet's example Explanation: The only common thing between the two examples is that both are countdown timers... And its just a example . I posted it here because the threads title reads "AutoIt Snippets" (This isn't part of the debate)... @boththose Thanks P.S Don't take that debate seriously
  16. @JLogan3o13 ...Well...I don't know what to say
  17. @mLipok Yeah, The GUI's controls were not responding. I think the GUI's loop broke (Its like when you create a GUI without a while loop to listen for any messages)
  18. Second Contribution... Small but neat when you use it ; #FUNCTION# ==================================================================================================================== ; Name ..........: CalcPercent ; Description ...: Calculates Percentage ; Syntax ........: CalcPercent($iPartDone, $iTotal[, $iRoundToDecimalPlace = 1]) ; Parameters ....: $iPartDone - Value of the part which is done. ; $iTotal - The total value. ; $iRoundToDecimalPlace- [optional] Round upto which decimal place?. Default is 1. ; Return values .: Percentage (without % symbol) ; Author ........: TheDcoder ; Modified ......: ; Remarks .......: ; Related .......: ; Link ..........: http://bit.ly/CalcPercentForAutoIt ; Example .......: Yes, See below ; =============================================================================================================================== Func CalcPercent($iPartDone, $iTotal, $iRoundToDecimalPlace = 1) Return Round(($iPartDone / $iTotal) * 100, $iRoundToDecimalPlace) ; Calculate percentage, round it & return it! EndFunc ;==>CalcPercent ; Example $iCountdown = 60 * 5 ; the value is in seconds ProgressOn("Example for CalcPercent function", "Countdown upto " & $iCountdown & " seconds") $hTimer = TimerInit() For $i = 1 To $iCountdown ProgressSet(CalcPercent($i, $iCountdown)) Sleep(1000) Next $iTime = TimerDiff($hTimer) $iTime /= 1000 ProgressOff() MsgBox(64, "Done!", "The countdown has ended! That took ~" & Round($iTime, 1) & " Seconds.")Hope it may help you, TD P.S Don't reply to this with rude reasons like "Hey! that is so simple! even a newbie can do that." or "It ain't worth posting in snippets section"
  19. @mLipok It was a nice for a free tool until the whole GUI froze
  20. @mLipok Its almost like the free version but with translation support, useless for me Edit: English version can be found here
  21. Oh, So CHM files are gonna retire soon... Thanks for the info, TD
  22. @RTFC Thanks, But I hate the text bar it adds. TD
×
×
  • Create New...