Jump to content

Quafboy

Members
  • Posts

    5
  • Joined

  • Last visited

Quafboy's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Thank's a million!!!!! That was exactly what I needed: Local $avLines = StringSplit( $txt, @CRLF, 1) _ArrayDisplay($avLines) I really appreciate it. IT was driving me crazy and no matter how many time's I read AutoIt help file I couldn't for the life of me figure this out. I'm still very much a beginner. Thank you thank you thank you.
  2. Firstly, kudos to the great AutoIT community. You have saved my butt at work numerous times by allowing me, a simple mind, to automate tasks that would be tedious and time consuming. Nod's specifically to valik and Smoke who have answered problems others have asked that pertain to problems I had numerous times. I am very grateful for you all. I swear I utilized search before posting this so if it has already been posted, by all means direct me accordingly. Now my problem. I can't think of a simple way to take clipboard contents and direct them into an array without using filereadtoarray which defeats the purpose of what I am trying to do. What I aim to accomplish is copying text out of notepad (multi-line) and put it into an array. Here is the code I have thus far: #include <Array.au3> Opt("WinWaitDelay",100) Opt("WinTitleMatchMode",4) Opt("WinDetectHiddenText",1) WinWait("Untitled - Notepad","") If Not WinActive("Untitled - Notepad","") Then WinActivate("Untitled - Notepad","") WinWaitActive("Untitled - Notepad","") Send("{CTRLDOWN}a{CTRLUP}") Send("{CTRLDOWN}c{CTRLUP}") $txt = ClipGet() StringSplit( $txt, @CRLF, 1) ;MsgBox(0,"test", $txt, 0) Local $ClipTxtArray[5] _ArrayAdd( $ClipTxtArray, StringSplit( $txt, @CRLF, 1)) _ArrayDisplay($ClipTxtArray) I would like to set the array size based on the number of @CRLF stringsplit processed instead of my finite number 5. What do I need to do to achieve this task? IF you don't want to give me the direct code could you please tell me what I need to do my homework on to arrive at a solution? Thank you all kindly.
  3. Download the source code for netcat. This should be a good reference for rolling your own prog. But don't directly steal code because A. it's wrong and b. antivirus will flag it for similarities to netcat.
  4. Thanks so much for posting this. I'm starting a Myspace library.
  5. Hello everyone, not to bring up an old post or anything but I just wanted to throw my two cents in. The code above works WAY better than the huge block a couple posts up. CODE$content1 = FileRead("C:\227953.doc", 99999) $text = StringReplace(BinaryToString($content1), Chr(0), "") $text = StringRegExpReplace($text, "(?s)(\x13.+?)\x14(.*?)\x15?", "$1" & Chr(21) & "$2") $text = StringRegExpReplace($text, '(?s)\x13(.*?)\x15', "") $text = StringRegExpReplace($text, "[^[:space:]|[:print:]]", "") $text = StringRegExpReplace($text, "\v", @CRLF) FileWrite("C:\output.txt", $text) I haven't really changed anything yet but I'll post the updated code when I get it just how it should be. PS I'm talking about tables in the test sample. I'm writing to a txt document to check the end result. Also I just wanted to say that I have been floating around these forums for a while but felt compelled to join the party after this post. I love AutoIT and I continue to be fascinated by the great work you all do and the amount of effort put into your code, especially since I am a beginner and need all the help I can get. Thanks to you all.
×
×
  • Create New...