Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 07/13/2015 in all areas

  1. There are tons of languages, I'd really hate to see the all listed.
    2 points
  2. JohnOne

    Array help!

    The short answer which is all I have time for is to use the standard Excel UDF's which can be found in the help file, to get shut of all the Send and Win* business. lol.
    2 points
  3. Jon

    Forum Upgrade Status

    Added a "Post #" indicator at the top right of a post as I know some people like saying "look at post #4" rather than linking.
    2 points
  4. trancexx

    Ribbon

    Few years ago Microsoft introduced new UI feature that they named Ribbon. With the release of Windows 7 they added it as standard system feature. Windows Ribbon framework. You could say it's a new technology waiting to be fully embraced. Considering AutoIt is currently in some shitty stage Ribbons are not expected to be supported natively. Which is actually good thing because otherwise some developer could have GUICtrlCreateRibbon idiotic idea. Ribbons are beautiful things. In order to work with them you have to master objects. It's COM based technology. Some people will stop reading now, but really their shame. Anyway, this example is based on work by Mr. Michael Chourdakis. Guy really took deeper dive to ribbon thematic and made few very interesting articles. All is available on internet naturally, just google Michael Chourdakis Ribbon or something like that. So, the main thing to do is create so called Ribbon Framework Object. After that you have to initialize event handlers (two callback objects made with ObjectFromTag function) and load your Ribbon. Ribbon is loaded from resource, either one of your app or some other. I have compiled resource dll for this example so that scripts could be run non-compiled and still use ribbon command bar. Example shown here is not completely dummy, it uses all of the ribbon controls. Only it doesn't do anything smart besides that. ZIP: Ribbon.zip Inside the zip there is folder called Ribbon with two files RibbonExample_NEW.au3 and RibRes.dll. Extract that folder somewhere, run RibbonExample_NEW.au3 and enjoy the Ribbon beauty. There are few comments inline for easier comprehension of the overall script code. Thanks Andreik for asking for more.
    1 point
  5. [NEW VERSION] - 17 Mar 22 Added: A new function _Notify_Size which allows you to adjust the size of the notification from its default 160x40. Please read the function header to see the max/min sizes that you can set for the width and height - the function returns informative @error/@extended values if these are not respected. Regardless of the size set, each notification will still display only 2 lines of text with the size of font used set automatically by the UDF. New UDF in the zip below. Previous changes: Changelog.txt A while ago I was asked to help port an AHK UDF to AutoIt. This was not too difficult and I found it useful myself (as a replacement for ConsoleWrite when debugging compiled scripts among other things). I have been polishing it for a while and thought I might release it in case it proves useful to anyone else. The notifications produced by Notify are small 2-line boxes that pop out of the edge of the display one above the other (you can select which side and in which direction they appear) - you can have as many as you want although only as many as can fit on your display will appear, the others will appear as soon as there is room. You can select whether they will retract after a certain time and/or when clicked. Colours and font are user-definable, and you can add an icon or image (bmp, jpg, gif or png) if you wish. When a notification retracts, the others move to leave space for more (you can select a smoooth slide or an instant move) - run the examples to see them in action. If you find the default sizing of the notifications is not to your liking you can change it by amending these values in the UDF (lines #354-356): ; Set default auto-sizing Notify dimensions Local $iNotify_Width_max = 300 Local $iNotify_Width_min = 150 Local $iNotify_Height = 40 A zip containing the UDF, example scripts and my StringSize UDF (which is also required): Notify.zip As usual happy for comments and/or compliments. M23
    1 point
  6. Danyfirex

    libZPlay UDF

    Hi all. some time without share something. today I made this UDF because I really like this library so I wanted to share with all you. libZPlay (Win32) Version 2.02 06. May, 2010. This is multimedia library for playing mp3, mp2, mp1, ogg, flac, ac3, aac, oga, wav and pcm files and streams. New: version 2.02 can also record sound from soundcard and encode into disk file with mp3, ogg, flac, aac or wav encoder. For more information look into the LibzPlay Page.txt file into the zip file. About the libZPlay UDF supports playing mp3, ogg, AAC, AC-3, flac, wav, pcmUNICODE support for functions using strings ( filename, error messages, ID3 info, ... ) REVERSE PLAYING (you can play song backward in real time, "real" backward playing without predecoding in PCM) built in echo and reverb sound processor internal volume control (without affecting wave out device volume) pulling VU meter data (you can simply create VU meter) built in FFT spectrum graph, library will draw complete spectrum graph on your window ibzPlayExample.au3 Capture: LibzPlayAU3.zip File contents libZPlay.au3libzPlayExample.au3libZPlayform.kxf LibzPlay Page.txt License.txt- From the libZPlay SDKReadme.txt - From the libZPlay SDKChangeLog.txt - From the libZPlay SDKlibzplay.dll - From the libZPlay SDKlibzplay.chm - From the libZPlay SDKlibzplay.chw - From the libZPlay SDK Download: LibzPlayAU3.zip Saludos
    1 point
  7. Jon

    AutoIt v3.3.14.2 Released

    AutoIt v3.3.14.0 has been released. Thanks to everyone involved, both visible and behind the scenes. Download it here. Complete list of changes: History Note The Map functionality was disabled in this release as it was not ready. I will release another beta version later with it re-enabled for continued dev and test.
    1 point
  8. GUIAccelerators()?
    1 point
  9. So if your script is returning an error because the internet connection is not yet established, wouldn't it simply make sense to create a While loop that pauses execution of the script until that connectivity is present??
    1 point
  10. Yes, we absolutely still need to fix the issue. This workaround works but it's absolutely terrible in terms of ease of development.
    1 point
  11. By the way, I was personally also very disappointed with AutoIt not having the functionality when AHK had it for years. In fact, that was the primary motivation behind the project. I think this is very important functionality and so I understand where you are coming from.
    1 point
  12. I agree. Just came up with the demo before you posted. As I don't like to waste code, I thought I would post anyway #include <MsgBoxConstants.au3> Local $sString = 'I am a string' Local $iNumber = 0 MsgBox($MB_SYSTEMMODAL, '', $sString == $iNumber) ; Compare value and type MsgBox($MB_SYSTEMMODAL, '', $sString = $iNumber) ; Compare value (auto convert) MsgBox($MB_SYSTEMMODAL, '', $iNumber == $sString) ; Compare value and type MsgBox($MB_SYSTEMMODAL, '', $iNumber = $sString) ; Compare value (auto convert)
    1 point
  13. Celtic88, No. You need to make sure comparisons are made between similar datatypes or you get strange results - as you have seen. In this case the lefthand side of the comparisons appears to be a number so AutoIt converts the righthand side to that type as well - and converting non-numeric strings to numbers sets them to 0, so the comparison is correct. You need to force string comparisons by using the String function or the == operator like this: local $NewSocketFiletransfertyp =0 local $Compvar = String($NewSocketFiletransfertyp) = "[DOUNLOAD]" msgbox(16,$Compvar,$NewSocketFiletransfertyp)M23 P.S. Third time I have had to explain this in 2 days. I even added some remarks to the Help file to explain, but it seems no-one ever bothers to read it - makes you wonder if it is worth the trouble.
    1 point
  14. Because you're comparing a number with a string and like JavaScript or PHP (for example), AutoIt converts the string to a number, which is zero. It's documented in the help file.
    1 point
  15. Did you try what I suggested you ? Local Const $Source = @ScriptDir Local Const $Destination = @TempDir $SourceFiles1 = _FileListToArray($Source,"*",$FLTA_FILES) For $i = 1 to $SourceFiles1[0] If FileExists($Destination & "\" & $SourceFiles1[$i]) Then FileCopy($Source & "\" & $SourceFiles1[$i], $Destination & "\" & $SourceFiles1[$i], 1) Next
    1 point
  16. jguinch

    Delete link instead of target

    It seems to be a desired behaviour from Windows. You have to add an additional entry specially for the lnk files : [HKEY_CLASSES_ROOT\lnkfile\shell\Delete Permanently\command] @="\"C:\\Program Files\\Permanent Delete\\Delete Permanently.exe\" \"%1\""
    1 point
  17. Pilot123, I take it you are lost for words when you look at the solution I posted? M23
    1 point
  18. Explain "somewhere in the nowhere^^"
    1 point
  19. Are you trying to look at a string and see if it is formatted as an IP address? xxx.xxx.xxx.xxx? If so, have a look at StringRegExp to test for a pattern. If that is not what you are after maybe you could post in your native language as something may be getting lost in translation (or use Google translate to explain).
    1 point
  20. Hi! I made this class because many of my AutoIt projects have to generate PDF files (logs, incomes...), and I always have to FileInstall() wkhtmlto*.exe and care about arguments, putting them in temporary folder then deleting it and many other always-the-same boring things. It's a class/object. It uses AutoItObject (which is already included). The wkhtmltopdf.exe and wkhtmltoimage.exe files are also included. All you must do to start using the class is including just the class file and instancing the class. Here's an example: #include "class\wkhtmltox.au3" Local $oObject = WKHtmlToX() $oObject.Input = "http://microsoft.com/" $oObject.Output = "microsoft.pdf" ; relative to current working dir $oObject.Convert() ; Now converting the same page into PNG $oObject.ToFormat = "png" $oObject.Output = "microsoft.png" $oObject.Convert()Help file included. Download file is just a redirect link because of the file size (14 MB because of wkhtmlto*.exe). The forum upload seems not to be working. Download full script (13,7 MB) AutoIt Forum Files: https://www.autoitscript.com/forum/files/file/343-wkhtmktox/ Dropbox: https://www.dropbox.com/s/xzw1l0b0y08mv8z/wkhtmltox.zip?dl=0 License info As wkhtmltopdf is LGPL, you can use it on a proprietary software, since you tell that you're using it (a link to http://wkhtmltopdf.org on the help files and About dialog would be cool...) Please check AutoItObject and CreateFilesEmbedded licenses: https://www.autoitscript.com/forum/topic/110379-autoitobject-udf/ and https://www.autoitscript.com/forum/topic/132564-createfilesembeddedau3-like-fileinstall/ This class is just a wrapper, so you don't need to tell anything about it on your app.
    1 point
  21. trancexx

    Ribbon

    I used Visual Ribbon Creator by Michael Chourdakis.
    1 point
  22. Hi, #include <GUIConstantsEx.au3> Global $hGui, $ChkBox[1], $Msg, $WGP $hGui = GUICreate("", 135, 25) $ChkBox[0] = GUICtrlCreateCheckbox("Add another checkbox", 5, 5, 125, 15) GUICtrlSetResizing(-1, $GUI_DOCKMENUBAR) GUISetState() While 1 $Msg = GUIGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit Case $ChkBox[0] To $ChkBox[UBound($ChkBox) - 1] $WGP = WinGetPos($hGui) If GUICtrlRead($Msg) = $GUI_CHECKED Then ReDim $ChkBox[UBound($ChkBox) + 1] $ChkBox[UBound($ChkBox) - 1] = GUICtrlCreateCheckbox("Add another checkbox", 5, ((UBound($ChkBox) - 1) * 25) + 5, 125, 15) GUICtrlSetResizing(-1, $GUI_DOCKMENUBAR) If UBound($ChkBox) - 1 >= 2 Then GUICtrlSetState($ChkBox[UBound($ChkBox) - 3], $GUI_DISABLE) WinMove($hGui, "", Default, Default, Default, $WGP[3] + 25) Else GUICtrlDelete($ChkBox[UBound($ChkBox) - 1]) If UBound($ChkBox) - 1 >= 2 Then GUICtrlSetState($ChkBox[UBound($ChkBox) - 3], $GUI_ENABLE) ReDim $ChkBox[UBound($ChkBox) - 1] WinMove($hGui, "", Default, Default, Default, $WGP[3] - 25) EndIf EndSwitch WEnd Cheers
    1 point
×
×
  • Create New...