manudo Posted January 31, 2008 Share Posted January 31, 2008 hi, I use SciTE4AutoIt3 Version 1.71 I have need to capture data provide by serial link and send file with xmodem protocol and capture data again. I use hyperterminal because I have tested different software (tera term pro ...) but i don´t have the same result than hyperterminal. Anyway, I find autoit and very happy to find this software. I read doc ... test ... write my first script for capture the data inside the hyperterminal. I use the function WinGetText and surprised the texte is "Connected 00:02:03" and not my data. I start AutoIt v3 window, check the visible text when I click on the principal window and the vivible text is "Connected 00:02:03" and I don´t see my data. The control info give me the information "Term Class1", Id 3, and nothing for the text. Do you have any idea for get the text or it´s not possible ? Thanks for your idea. Link to comment Share on other sites More sharing options...
whim Posted January 31, 2008 Share Posted January 31, 2008 Check "Title Special Definition" in the helpfile under "WinGetText"scroll to "Advanced Window Descriptions" :Advanced Window Descriptions A special description can be used as the window title parameter. This description can be used to identify a window by the following properties:TITLE - Window title CLASS - The internal window classname REGEXPTITLE - Window title using a regular expression (if the regular expression is wrong @error will be set to 2) LAST - Last window used in a previous AutoIt command ACTIVE - Currently active window INSTANCE - The 1-based instance when all given properties match One or more properties are used in the title parameter of a window command in the format:[PROPERTY1:Value1; PROPERTY2:Value2] e.g. Wait a window of classname "Notepad" WinWaitActive("[CLASS:Notepad]", "") Link to comment Share on other sites More sharing options...
manudo Posted January 31, 2008 Author Share Posted January 31, 2008 First, thanks for your answer. So I try with this script: Opt("WinTitleMatchMode", 4) ;1=start, 2=subStr, 3=exact, 4=advanced, -1 to -4=Nocase $text = WinGetText("[CLASS:SESSION_WINDOW; CLASSNAMENN:Term Class1]", "") MsgBox(0, "Text read was:", $text) But the result is the same, "Connected 00:02:03" or "disconnected" but not the data from the serial link. Link to comment Share on other sites More sharing options...
Shevilie Posted January 31, 2008 Share Posted January 31, 2008 Well haven't worked with the terminal, but I would have alook at StdoutRead (Look in the helpfile for that) Start here if you are new Valuater's AutoIT 1-2-3Looking for an UDF - Look hereDo you need to do it twice - Autoit Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now