Jump to content

Leaderboard

Popular Content

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

  1. argumentum

    Desktop Refresh

    @int3lln3t, I can not say "welcome to the forum" as you been here since 2015. I personally dislike the choice of font you've made. @Deye, thanks for sharing.
    1 point
  2. Just edit the first post in the thread and add [RESOLVED] in front of your title.
    1 point
  3. From the online help -- So, you'll need to use _FFObj, like this -- MsgBox(0, "_FFCmd('outerHTML'", _FFObj($sObject, 'outerHTML'))
    1 point
  4. I saw that this string exists (with various flavours) several times in the file. To remove them all you might use a more selective expression to limit the risk of errors StringRegExpReplace($str, '\$=<\$=T3\*1\s+\$=L\d+\*\d+', "")
    1 point
  5. ShellExecute("aut2exe.exe", '/in "' & $fileLocation & '"') What about this version? jos
    1 point
  6. Here it is $str = '$F$%$?$%- - - - - - - - - - - - - - - - - -Footnotes- - - - - - - - - - - - - - - - - -' & @crlf & _ '$Tn1 Subsequent to oral argument by letter, dated December 16, 2005 Scrushy''s attorney submitted to the Court a "Memo" dated 7/19/04 and apparently prepared by a Pamela Anderson. This "Memo" contains unverified, unsworn rank hearsay and the Court has not considered the contents of this document in reaching its decision.$%$?$%- - - - - - - - - - - - - - - - -End' & @crlf & _ ' Footnotes- - - - - - - - - - - - - - - - -$E$=P1298*3' ;msgbox(0,"", $str) $str2 = StringRegExpReplace($str, '\$%\$\?\$%[^\$]+', "") msgbox(0,"", $str2) This removes any non-$ char from "$%$?$%" up to the next $ char Please note that you have to first manage the single quote(s) included in the string
    1 point
  7. then reading thru this function in uiawrappers ;~ Just dumps all information under a certain object Func _UIA_DumpThemAll($oElementStart, $treeScope) together with example 1 would give you the solution The array of elements is for most people the easiest as they then just can loop with a for/next construction
    1 point
  8. example 1 where you can see with treewalkers how to walk thru the tree from a certain object (root is desktop) In the UIAWrappers in functions with find you can see how it works Be aware on the parameter that controls the number of childs you get and how many levels deep. All descendants inculding all grandgrandgrand childs is a time consuming job.
    1 point
  9. You have to examine the underlying event code to be able to figure out how to trigger the menu. In this case, there's a single event on the main container that is used for each of the objects within that container. The event looks at the position of the click to determine which element to actually trigger. Here's some code that will cause the menu to appear -- #Include <FF.au3> If _FFConnect(Default, Default, 3000) Then _FFXPath( "//div[@class='open-menu']") If @error = $_FF_ERROR_Success Then $pos = _FFCmd('FFau3.xpath.getBoundingClientRect().x') + 1 $cmd = "d=FFau3.WCD.createEvent('MouseEvent');d.initMouseEvent('click',true,true,window,0,0,0," & $pos & ",0,0,0,0,0,0,null);FFau3.xpath.parentNode.parentNode.parentNode.dispatchEvent(d);" _FFCmd($cmd) EndIf EndIf It creates a click event with the proper positioning value and then passes it to the container element to be processed.
    1 point
  10. Bert

    My script died

    I'm thinking there is a bigger question to be asked - Did Meoit even write the script?
    1 point
  11. Tested on Windows 10 x64 works fine, did you change the folders for Windows 7 x64? #include <Array.au3> #include <File.au3> Global $aArray = _FileListToArrayRec("C:\", "*||$Recycle.Bin;Program Files;Program Files (x86);Users;Windows", _ $FLTAR_FILES+$FLTAR_NOSYSTEM+$FLTAR_NOHIDDEN, _ $FLTAR_RECUR, $FLTAR_FASTSORT, $FLTAR_FULLPATH) _ArrayDisplay($aArray, "_ArrayDisplay is only showing the first 65.525 rows of the $aArray")
    1 point
  12. beelzeboul

    Capturewnd command

    im sorry you were right _ScreenCapture_CaptureWnd("d:\test\test.bmp", $test) did fix the error and took a screen shot but its of the desktop not the window.
    1 point
  13. See example 1 with treewalkers
    1 point
  14. This works well on my XP #include <Array.au3> #include <File.au3> Global $aArray = _FileListToArrayRec("C:\", _ "*||$Recycle.Bin;Program Files;Documents and Settings;Windows", _ $FLTAR_FILES+$FLTAR_NOSYSTEM+$FLTAR_NOHIDDEN, _ $FLTAR_RECUR, $FLTAR_FASTSORT, $FLTAR_FULLPATH) _ArrayDisplay($aArray, "_ArrayDisplay is only showing the first 65.525 rows of the $aArray")
    1 point
  15. Moved to the correct forum, as the DEV forum very clearly states:
    1 point
  16. mikell

    HELP ABOUT ARRAY

    The $USER_DETAILS array is declared as global (so reinitialized) in several funcs of _SimpleSystem_UDF.au3 There are error checkings missing in places. You might do a debug by inserting some ConsoleWrite into the udf, as this array is the result of HttpRequests and the trouble comes probably from there
    1 point
  17. TheDcoder

    HELP ABOUT ARRAY

    I tried to look at the script but everything is in Vietnamese so I gave up but I will offer you some general advice . Check what $USER_DETAILS contains, check what it should contain and then work your way in reverse direction deciphering the source of the contents of the array, then you will get an idea of what is going wrong But I think it is better to wait for someone, ideally the author of the script to respond at the Vietnamese forum. Good luck
    1 point
  18. What about this ? $txt = FileRead("ahihi.txt") $output = StringRegExpReplace($txt, '(?<!^|:)(?=\$(?:00|03|10|20|25|30|40|45|110|115|120|T))', @crlf) FileWrite("output.txt", $output) Meaning : Search positions (not preceded by start of text or a colon) and (followed by $00, $03 and so on) and at these positions insert a crlf
    1 point
  19. Floops you are an absolute legend, thank you so much for sparing yourtime to help me, that worked perfectly. I guess I will get more used to the functions the more I use it. Thanks again.
    1 point
  20. JLogan3o13

    My script died

    @meoit what have you done to troubleshoot this on your own? We're happy to help, but you have basically posted 1200+ lines of code with nothing more than "it's broke, fixt it for me" as an explanation. Are we to assume that, uncompiled, it is working as you would expect? Have you put any work into taking the time to narrow down where it is failing? RIght at the outset, halfway through, you see it do step 1 but not step 2, etc? You have a number of functions, how far does the script get before it fails? The more information you can provide, the better able we are to assist.
    1 point
  21. The above code was only an example based on the provided .txt In post #1 you asked for a table with columns, so : - FileReadToArray is used to get rows - Then on each row, StringSplit is used with colon as delimiter to get the content of the 2 columns Of course if the file is formatted differently, you will need to manage the text differently too Look at the comments in the code below $file = @ScriptDir & "\psinfo.txt" ; get the array of rows $array = FileReadToArray($file) ; declare the variable to store the html content $html = "" ; add the content using concatenation $html &= '<head></head><br><img style="margin-left: 30px;" src=logo-csm.png>' ;</big></td></tr></tbody></table><br style='font-family: Calibri'><big style='font-family: Calibri font-weight: bold'> </big>" $html &= '<h2 style="width:95%; background-color:#4b8df8; margin-left: 30px; border: 0px solid #4b8df8; color:white; font-family:verdana">Scans</h2>' & @CR $html &= '<table style="width:95%; height:50%; margin:-21px; margin-left: 30px; border: 3px solid #4b8df8;">' & @crlf ; loop through rows For $i = 0 to UBound($array)-1 ; split each row with colon as delimiter $tmp = StringSplit($array[$i], ":") ; build the table $html &= "<tr>" & @crlf $html &= "<td>" & $tmp[1] & "</td>" & @crlf ; col 1 $html &= "<td>" & StringStripWS($tmp[2], 3) & "</td>" & @crlf ; col 2 $html &= "</tr>" & @crlf Next $html &= "</table>" & @crlf FileWrite(@ScriptDir & "\test.html", $html); save file
    1 point
  22. Here is a basic script to show how this could be done using AutoIt $file = @ScriptDir & "\psinfo.txt" $array = FileReadToArray($file) $html = $array[0] & "<br><br>" & @crlf $html &= "<table border=0 width=500>" & @crlf For $i = 1 to UBound($array)-1 $tmp = StringSplit($array[$i], ":") $html &= "<tr>" & @crlf $html &= "<td>" & $tmp[1] & "</td>" & @crlf $html &= "<td>" & StringStripWS($tmp[2], 3) & "</td>" & @crlf $html &= "</tr>" & @crlf Next $html &= "</table>" & @crlf FileWrite(@ScriptDir & "\test.html", $html); save file
    1 point
  23. Jon

    Forum Information and FAQs

    User Groups and Rights New Members - New members with that joined the forum within the last day. While in this group there are certain restrictions on the number of posts/PMs that can be made. This is to reduce the impact of spammers. After 24 hours members of this group will be promoted the Members group. Members - Members older than one day but with less than 20 posts. Standard access to the forum. Active Members - Members with more than 20 posts have additional rights No advertsSlightly more generous attachment and PM limitsAccess to the Chat forumAbility to upload files to the Downloads section MVPs - Members who are judged by the community to be helpful, who write and share useful code, who help the development of AutoIt. These users have the same rights as normal members but get a team icon, a little more attachment and PM space, and access to the MVP Chat forum section. Moderators - The forum police. This is not a democracy and each of the mods has their own distinct personality. They have the rights to edit posts, delete posts, ban users, delete users, IP ban, etc. Let the poster beware. Developers - A small group of users with access to the AutoIt source code and who have contributed significantly to the internal development of AutoIt. Some of them are also Moderators. Post Count and Rankings Ranks based on increasing post count are as follows: SeekerWayfarerAdventurerProdigyPolymathUniversalistThese titles are auto-generated and have no relation to actual skill level. Once you reach 300 posts you can change the title to whatever you like.
    1 point
×
×
  • Create New...