1) You most likely will want the software configured for Operator mode - see My-T-Soft Setup | Configuration | Special options
2) You will not want the users to drag or move the window - turn off Action button move in My-T-Soft Setup | Configuration | Operation Options
3) When your dialog is shown, you can use GetWindowRect to identify screen coordinates - based on the configuration of My-T-Soft, you can position the window (using a little math) to a fixed spot on the dialog - for example, if you want the keyboard at a relative offset of X 100, Y 44, you would: RECT rcdialog,rcmytsoft; HWND hMyTSoft; hMyTSoft = FindWindow(NULL,"My-T-Soft"); GetWindowRect(hMyTSoft,rcmytsoft); GetWindowRect(hmydialog,&rcdialog); MoveWindow(hMyTSoft,rcdialog.left+100,rcdialog.top+44, rcmytsoft.right-rcmytsoft.left, rcmytsoft.bottom-rcmytsoft.top,TRUE);
4) You will probably want to catch the WM_MOVE message, and do something similar (or put the positioning code into a function) in case the dialog is moved to a new location.
5) If the dialog is sizeable, you will have to catch WM_SIZE.
The typical approach which is much easier is to define configurations & screen position, then call up the configuration when the particular control has focus. Often there are only a handful of fields that require text input. Higher level environments like VB or MS-Access have "OnEnter" & "OnExit" events, which can be used to call up the configurations. We always recommend you position My-T-Soft off-screen when you don't want it available for the user, then bring it on screen at the desired location when required.
Original ID: QD253438
|Category: Integrating(Developing)||Type: Question/Answer||Product: My-T-Soft|