Page 1 of 1

Child Window not moving with WinMove

Posted: 29 Aug 2019, 23:59
by bxdobs
Trying to automatically import a csv file in to a windows application
The app's import window has no min max buttons but can be manually moved
The app retains the last position of this import window which is becoming problematic to this automation process
The window can move outside the bounds of the Parent window

There is a filename field, a combo box, and a close button that need to be accessed in order to complete the import process
The only way I have successfully been able to use this Window is by using a combination of Send to fill in the Filename and Click coordinates
to select Combo options or push the Button

send I{tab}%flnm%{enter}
click x,y

At issue, if someone manually moves the window, all the Click X, Y coordinates have the potential to be off their mark causing import failures

as such, I was attempting to move this Child Window to a fixed location to obtain consistent Coordinates using the following command
WinMove WinTitle,, 0, 160

WinSpy shows a Windows Title of Import / Export

Issue 1)
As WinSpy shows this as a window, not sure why auto key click is using the parent windows X Y coordinates

Issue 2)
neither 'WinMove Import,, 0,160' nor 'WinMove "Import / Export",, 0,160' move this child window


Thanks in advance

Re: Child Window not moving with WinMove

Posted: 30 Aug 2019, 03:19
by Xtra
I use ControlMove on MDI windows give it a try.

Re: Child Window not moving with WinMove

Posted: 30 Aug 2019, 14:50
by bxdobs
Turned out this had to do with a Case Sensitive Character in the Control name