MidwayMonster Posted May 4, 2012 Posted May 4, 2012 Hello, I support registers at a number of retail stores that run an application named Triversity POS XPress. In the past when I would want to automate certain processes I would use the WinWaitActive command to pause the script until the window i wanted would show up. The problem I am having is besides the Title and Class. I cannot seem to get any feedback on what the POS is showing, any status etc. Not even what the labels on the buttons say. I have tried to use the Window Info utility and looked in Hidden and Visible Text but they show the same items regardless of the status of the POS so nothing helpful there. If i use the Window Info utility on a button specifically I get the Class (Button) and the Instance but no Labels or text that it is showing. I would love to be able to use AutoIT to automate a number of our processes which on the surface appeared to be very simple since its all keyboard strokes anyways. I am hoping there is a advanced method of collecting some information through APIs or something. In the end what I am trying to do is have the script read the current status at certain points and depending on the status react a certain way or wait. I can code all of that. Just need help on inteacting with the app better. Any feedback including RTFM :-) is appreciated... (But with RTFM point me in the right direction because i have) Here is the Summary tab of Window Info for the full App: (NEXT 2 will be a Button and the main Text area. But only the Window and control portion as all other sections are the same) ***** Whole Window App >>>> Window <<<< Title: POS Xpress TERM#83 Class: AfxFrameOrView42 Position: 0, 0 Size: 800, 600 Style: 0x94800000 ExStyle: 0x00000000 Handle: 0x002103F8 >>>> Control <<<< Class: AfxWnd42 Instance: 1 ClassnameNN: AfxWnd421 Name: Advanced (Class): [CLASS:AfxWnd42; INSTANCE:1] ID: 4 Text: Prompt Position: 20, 10 Size: 456, 48 ControlClick Coords: 62, 38 Style: 0x50000000 ExStyle: 0x00000000 Handle: 0x0026039A >>>> Mouse <<<< Position: 83, 49 Cursor ID: 0 Color: 0x000000 >>>> StatusBar <<<< >>>> ToolsBar <<<< >>>> Visible Text <<<< F1 F2 F3 F4 F5 F6 F7 F8 Prompt Receipt Total Instruction Terminal Cashier Date Time TXNNum Menu Status Status Status Status Status Status Status Status Status Status >>>> Hidden Text <<<< F9 F10 F11 F12 Identification Transaction Scale Display Customer TXNState SubTotal Tax Total2 Items Quantity OK Cancel ***** BUTTON WIndow and Control Sections >>>> Window <<<< Title: POS Xpress TERM#83 Class: AfxFrameOrView42 Position: 0, 0 Size: 800, 600 Style: 0x94800000 ExStyle: 0x00000000 Handle: 0x002103F8 >>>> Control <<<< Class: Button Instance: 13 ClassnameNN: Button13 Name: Advanced (Class): [CLASS:Button; INSTANCE:13] ID: 1000 Text: Position: 515, 121 Size: 116, 96 ControlClick Coords: 51, 50 Style: 0x5000000B ExStyle: 0x00000000 Handle: 0x002103C8 ***** Status Window - WIndow and Control Sections >>>> Window <<<< Title: POS Xpress TERM#83 Class: AfxFrameOrView42 Position: 0, 0 Size: 800, 600 Style: 0x94800000 ExStyle: 0x00000000 Handle: 0x002103F8 >>>> Control <<<< Class: Instance: ClassnameNN: Name: Advanced (Class): ID: Text: Position: Size: ControlClick Coords: Style: ExStyle: Handle: Keith Keith Hugginswww.LivingViLife.com | [email="Keith.Visalus@gmail.com"]Keith.Visalus@gmail.com[/email]Want to automate your weightloss and fitness? I lost 20 pounds and 5 inches across my belly in 8 weeks without exercise!Check out my website or shoot me a email for more information
stormbreaker Posted May 5, 2012 Posted May 5, 2012 Search Help-File for Window Titles and Text (Advanced). Perhaps that could be of help. Do provide feedback. ---------------------------------------- :bye: Hey there, was I helpful? ---------------------------------------- My Current OS: Win8 PRO (64-bit); Current AutoIt Version: v3.3.8.1
MidwayMonster Posted May 7, 2012 Author Posted May 7, 2012 Thank you let me look into that and will respond with what i find. Keith Hugginswww.LivingViLife.com | [email="Keith.Visalus@gmail.com"]Keith.Visalus@gmail.com[/email]Want to automate your weightloss and fitness? I lost 20 pounds and 5 inches across my belly in 8 weeks without exercise!Check out my website or shoot me a email for more information
MidwayMonster Posted May 7, 2012 Author Posted May 7, 2012 Although this is good information it doesnt really fit the issue I am trying to resolve. Luckily there is only 1 window so determining the window by title or simply [Active] is not a problem. The issue I am facing is that under certain situations the keys strokes used will be different depending on the current state of the register at that time. but as i posted in the Window Info Summary, there is no screen output text provided from this app. So here is an example using a login process. normally you would type in the username {enter} Send the password {enter} ... now if they registe has already been opened for the day no problem you get right in. But if it hasnt it prompts... do you want to open the register {F1} yes {F2} No. After that there are other windows and prompts you have to wait and watch for. So I am trying to get the script to read the screen output so i can build in the necessary logic to act accordingly. I hope this makes more sense... Keith Hugginswww.LivingViLife.com | [email="Keith.Visalus@gmail.com"]Keith.Visalus@gmail.com[/email]Want to automate your weightloss and fitness? I lost 20 pounds and 5 inches across my belly in 8 weeks without exercise!Check out my website or shoot me a email for more information
kaotkbliss Posted May 7, 2012 Posted May 7, 2012 Are all the window sizes the same for each prompt? if not does each prompt vary in size and are they consistant? if so you can use WinGetPos and check the elements 2 and 3 to match the size 010101000110100001101001011100110010000001101001011100110010000 001101101011110010010000001110011011010010110011100100001 My Android cat and mouse gamehttps://play.google.com/store/apps/details?id=com.KaosVisions.WhiskersNSqueek We're gonna need another Timmy!
MidwayMonster Posted May 7, 2012 Author Posted May 7, 2012 Thanks Kaotkbliss I will check that out right now. Just as a update I have been playing with WinGetText and ControlGetText. I am able to see the Control ID and reference it but it is unable to read the text on the button. Also the main status bar only shows "Prompt" regardless of what it actually sais lol. to answer your questions: No, each area are different sizes but the layout is very static and doesnt change. Keith Hugginswww.LivingViLife.com | [email="Keith.Visalus@gmail.com"]Keith.Visalus@gmail.com[/email]Want to automate your weightloss and fitness? I lost 20 pounds and 5 inches across my belly in 8 weeks without exercise!Check out my website or shoot me a email for more information
MidwayMonster Posted May 7, 2012 Author Posted May 7, 2012 it just returns 0,0,800,600 to show the position and window size... Keith Hugginswww.LivingViLife.com | [email="Keith.Visalus@gmail.com"]Keith.Visalus@gmail.com[/email]Want to automate your weightloss and fitness? I lost 20 pounds and 5 inches across my belly in 8 weeks without exercise!Check out my website or shoot me a email for more information
MidwayMonster Posted May 7, 2012 Author Posted May 7, 2012 I will be opening a ticket with SAP too see if they have any suggestions that may help. But still looking for a solution in the mean time so any more responses are appreciated. Keith Hugginswww.LivingViLife.com | [email="Keith.Visalus@gmail.com"]Keith.Visalus@gmail.com[/email]Want to automate your weightloss and fitness? I lost 20 pounds and 5 inches across my belly in 8 weeks without exercise!Check out my website or shoot me a email for more information
MidwayMonster Posted May 8, 2012 Author Posted May 8, 2012 Still waiting for SAP to see if they know of a way to interact with them. But an update from my testing. Not all situations but a few cause a error message in a popup window. using the WinGetState command i can look for these errors. now i can read the text through the script but can at least see if its there. I have to use WinGetState as this popup always exists and isnt active when its shown. WinGetState returns a value of 3 showing that it exists and is visible. Keith Hugginswww.LivingViLife.com | [email="Keith.Visalus@gmail.com"]Keith.Visalus@gmail.com[/email]Want to automate your weightloss and fitness? I lost 20 pounds and 5 inches across my belly in 8 weeks without exercise!Check out my website or shoot me a email for more information
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