Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 07/28/2015 in Posts

  1. Jon

    AutoIt v3.3.14.2 Released

    Uploaded v3.3.14.1 Removed au3record.exe as it's often mistakenly flagged as malware causing the entire AutoIt zip/installer to be flagged. We'll host it separately.Reworked AutoIt3Help.exe and applied a digital signature to help with malware false positives - as above.No other changes to the AutoIt exes so no real need to update if you are not having issues.
    2 points
  2. Danyfirex

    Get Portable Devices

    Well an Implementation of IPortableDeviceManager Interface to get all Portable Device conected to our pc. #include <Array.au3> #include <WinAPICom.au3> Opt("MustDeclareVars", 1) Global Const $sCLSID_PortableDeviceManager = "{0af10cec-2ecd-4b92-9581-34f6ae0637f3}" Global Const $sIID_IPortableDeviceManager = "{a1567595-4c2f-4574-a6fa-ecef917b9a40}" Global Const $sTagIPortableDeviceManager = "GetDevices hresult(ptr;dword*); RefreshDeviceList hresult(); " & _ "GetDeviceFriendlyName hresult(wstr;wstr;dword*); GetDeviceDescription hresult(wstr;wstr;dword*); " & _ "GetDeviceManufacturer hresult(wstr;wstr;dword*); GetDeviceManufacturer hresult(wstr;wstr;ptr;dword*dword*); " & _ "GetPrivateDevices hresult(ptr;dword*)" Global Enum $eDevID, $eDevName, $eDevManufacturer, $eDevDescription Local $aPnPDevices = GetPortableDevices() If IsArray($aPnPDevices) Then _ArrayDisplay($aPnPDevices) ;~ Success: Return 0 ;~ Failure: Return 2DArray [n][4] |;[n][0]$eDevID, [n][1]$eDevName, [n][2]$eDevManufacturer,[n][3] $eDevDescription Func GetPortableDevices() Local $aDevicesInfo[0][0] ;[n][0]$eDevID, [n][1]$eDevName, [n][2]$eDevManufacturer,[n][3] $eDevDescription Local $oPortableDeviceManager = 0 Local $SizeofArray = 0 Local $hr = 0x80004005 ;E_Fail Just to Initialized <0 Local $taPnPDeviceIDs = 0 Local $tName = 0 $oPortableDeviceManager = ObjCreateInterface($sCLSID_PortableDeviceManager, $sIID_IPortableDeviceManager, $sTagIPortableDeviceManager) If Not IsObj($oPortableDeviceManager) Then Return 0 If FAILED($oPortableDeviceManager.GetDevices(Null, $SizeofArray)) Then Return 0 If $SizeofArray < 1 Then Return 0 $taPnPDeviceIDs = DllStructCreate("ptr[" & $SizeofArray & "]") If FAILED($oPortableDeviceManager.GetDevices(DllStructGetPtr($taPnPDeviceIDs), $SizeofArray)) Then Return 0 ReDim $aDevicesInfo[$SizeofArray][4] For $i = 0 To $SizeofArray - 1 $tName = DllStructCreate("wchar[512]", DllStructGetData($taPnPDeviceIDs, 1, $i + 1)) $aDevicesInfo[$i][$eDevID] = DllStructGetData($tName, 1) $aDevicesInfo[$i][$eDevName] = _GetFriendlyName($oPortableDeviceManager, $aDevicesInfo[$i][$eDevID]) $aDevicesInfo[$i][$eDevManufacturer] = _GetDeviceManufacturer($oPortableDeviceManager, $aDevicesInfo[$i][$eDevID]) $aDevicesInfo[$i][$eDevDescription] = _GetDeviceDescription($oPortableDeviceManager, $aDevicesInfo[$i][$eDevID]) $tName = 0 _WinAPI_CoTaskMemFree(DllStructGetData($taPnPDeviceIDs, 1, $i + 1)) Next Return $aDevicesInfo EndFunc ;==>GetPortableDevices Func _GetDeviceManufacturer($oInterface, $PnPDeviceID) Local $sString = "" $oInterface.GetDeviceManufacturer($PnPDeviceID, $sString, 128) Return $sString EndFunc ;==>_GetDeviceManufacturer Func _GetDeviceDescription($oInterface, $PnPDeviceID) Local $sString = "" Local Const $Size = 128 $oInterface.GetDeviceDescription($PnPDeviceID, $sString, 128) Return $sString EndFunc ;==>_GetDeviceDescription Func _GetFriendlyName($oInterface, $PnPDeviceID) Local $sString = "" Local Const $Size = 128 $oInterface.GetDeviceFriendlyName($PnPDeviceID, $sString, 128) Return $sString EndFunc ;==>_GetFriendlyName Func _GetProperty($oInterface, $PnPDeviceID) Local $sString = "" Local Const $Size = 128 $oInterface.GetDeviceFriendlyName($PnPDeviceID, $sString, 128) Return $sString EndFunc ;==>_GetProperty Func FAILED($hr) Return ($hr < 0) EndFunc ;==>FAILED Saludos
    1 point
  3. Hi there! I'm looking for some team members for a bigger software project, namely Perseus ( https://github.com/Perseus-Dev/Perseus-6 ). Your profile: You have fun programming,you are proficient in AutoIt and you have touched VB.NET (or VBS) at some point,you are interested in compiler development and the inner workings of programming languages, but you don't want to start from scratch,you can spare some time for this,you have crazy, yet somewhat useful ideas.Short history of this project: 2013: Project started as a primitive AssemblerAssembler development was completed, published as "ActiveX Light Assembler" (can be found in my threads here)Plan to evolve Assembler into primitive programming language2014: First version of Perseus ("Unknown Universe") was released, basically a self-compiler. Used FASM as the Assembler.Following community input, the second version was released ("Caffeinated Cat")2015: Development of Perseus 5 began (working title is "Perseus++"), built on a framework called DirectByte, Assembler no longer needed.First version of Perseus++ released, very Pascal-like syntax, many bugsMid 2015: Perseus 6 Development started, first beta version of Perseus 6 was released, first version to be completely open-source.Perseus 6 syntax cleanup, heavy changes to the syntax, now more C-like, but much easier, added a bunch of featuresThe next steps in development: Port the whole Perseus source code to AutoIt, eliminate VB.NET (the current main language)Redo the syntax debuggerPublish final version of Perseus 6 More information about the language in its very long README on the project page (link above). If you are interested send me a PM, if you have any questions, leave them here.
    1 point
  4. JLogan3o13

    How do you go advanced?

    Define "know the basics". It depends on what interests you: If you like graphical projects, do a search for GDI+ on the forum (and make friends with UEZ). If you come from another language and want some understanding of how to approximate C# or other OOP code, and can take honest (read that brutal) constructive criticism, do a search on the forum for some of Trancexx's work. If you're looking to do web automation, look at the IUIAutomation thread in the Examples forum. Without knowing what you're into, and with so much that AutoIt can do, it is a little difficult to point you in the right direction.
    1 point
  5. Hi I normally ignore new/hobby languages until they get a following, but this looks interesting. I think I really like the language. My experience is in C/C#/Python, but VB.NET would be easy and I can do AutoIT. I should also mention that my only personal PC at the moment is a Mac. Before I would consider committing to a project, I would need to know a few things: Do you have a roadmap? Goals?Your changelog looks like you haven't had a consistent plan (at least for extended periods of time); it seems like you've drifted to whatever happened to catch your interest. That's not a bad thing for a hobby project, but if you want a team working with you you'll need structure.Why do you want to port the code to another language? That means taking time from developing new features to do what you've already done.Why do you want to port the code to AutoIt, as opposed to a "standard" language like C, or to Perseus?Are you certain you want to keep the language Windows-only? .NET Core now runs on Linux and OS X, so could it become cross-compatible, or has it's design already been tied too closely to Windows? (I see Windows.inc, but I'm wondering if we could have an OSX.inc, then maybe set another library on top for basic tasks, such as drawing windows -- that library would use whichever include files it needs for the architecture to which we're compiling.). Obviously, if you're going to use AutoIt, this question could be ignored.You spoke of community input in your post -- what community have you fostered? Where is everyone? How welcoming would they be when I join?--Ryan
    1 point
  6. New version: 28-07-2015, Version 0.6 Beta: Added: Installer, Now supports selection of AutoIt's folder Added: Added support for sorting Styles & ExStyles Fixed: Now does not count commas in strings as normal parameter commas Fixed: Typo "Importent" --> "Important" in Doc Please delete the "Magic Number Calculator" folder in appdata folder before replacing the old executable, TD
    1 point
  7. I kind of gave you the code already, do you not remember? Perhaps I should have been explicit! >> https://www.autoitscript.com/forum/topic/152146-au3-script-parsing-related-functions/ post #17 << Mine is better as it will retain the original strings whilst you do what it is you have to do. But since you want to replace entirely, here... Local $sPattern = '([''"])\V*?\1\s*' Local $sReplace = StringRegExpReplace('This is a "test" string', $sPattern, '') ; I need to remove anything which is enclosed within Quotes or Apostrophes (Single Quotes), So the return string needs to be: "This is a string" ConsoleWrite($sReplace)I would have expected a little bit of trying beforehand.
    1 point
×
×
  • Create New...