Bixby Sayz Posted November 12, 2012 Share Posted November 12, 2012 When you set a new client, where does SCAR get this information from? Does it poll the window for it? The reason I ask is when using the SMART client it reports the correct ImageArea information, but reports incorrect InputArea information, making it impossible to figure out where the SMART window resides on the desktop. Off topic: Did the forums go down for a bit? Couldn't get on for a few minutes, and Down Or Just Me reported it down as well. Quote Link to comment Share on other sites More sharing options...
FHannes Posted November 12, 2012 Share Posted November 12, 2012 Each TSCARClient subclass implements this stuff separately. So the boxes are pulled straight from the SMART wrapper library. How is the InputArea incorrect? This does not represent the position of the window on the desktop, this is only true for TSCARWindowClient, as a TSCARClient subclass doesn't necessarily handle a visible window, or even a window at all, like TSCARBitmapClient. And yes, I had to reboot the server. Quote Link to comment Share on other sites More sharing options...
Bixby Sayz Posted November 12, 2012 Author Share Posted November 12, 2012 Hmm. I'll have to take a different approach then. Since I've always been dealing with WindowClient so far InputArea has always corresponded to the ImageArea relative to the Desktop. Which enables me to grab a bitmap from the desktop using those coords. With SMART ImageArea and InputArea are set to the same thing, which completely pooches that idea. Quote Link to comment Share on other sites More sharing options...
FHannes Posted November 12, 2012 Share Posted November 12, 2012 Well, if I remember correctly, the SMART client has the PID in the title, which I believe you can also access with the API form the library, so you should be able to set up a window client by searching for that. Quote Link to comment Share on other sites More sharing options...
LordJashin Posted November 12, 2012 Share Posted November 12, 2012 Or just use OSI, and do a := FindWindowEx('SMART', etc. etc. b := TSCARWindowClient.Create(a) Quote Link to comment Share on other sites More sharing options...
Bixby Sayz Posted November 12, 2012 Author Share Posted November 12, 2012 Or just use OSI, and do a := FindWindowEx('SMART', etc. etc. b := TSCARWindowClient.Create(a) The problem is finding the correct SMART, which I have thanks to Freddy's suggestion. Now if only I could figure out a way to force SMART to the front without resorting to the windows api. Throws an access error when you call Activate(). Quote Link to comment Share on other sites More sharing options...
LordJashin Posted November 12, 2012 Share Posted November 12, 2012 ActivateWindow function... Quote Link to comment Share on other sites More sharing options...
Bixby Sayz Posted November 12, 2012 Author Share Posted November 12, 2012 (edited) ActivateWindow function...For some reason thought that function was removed. Getting senile. Now to figure out why activate kills the RS client (the standalone client). And all of this because I originally was dissatisfied with SMART not finding DTMs properly. I get sidetracked waaaaaaaaaaaay too easily. Edited November 12, 2012 by Bixby Sayz Quote Link to comment Share on other sites More sharing options...
LordJashin Posted November 12, 2012 Share Posted November 12, 2012 Dont we all... And the SMART window is setup so you cant activate it But can you do BringToFront? Im going to update the rsclient functions later... Quote Link to comment Share on other sites More sharing options...
FHannes Posted November 12, 2012 Share Posted November 12, 2012 For some reason thought that function was removed. Getting senile. Now to figure out why activate kills the RS client (the standalone client). And all of this because I originally was dissatisfied with SMART not finding DTMs properly. I get sidetracked waaaaaaaaaaaay too easily. If try GetOuterWindow because calling ActivateWindow. Quote Link to comment Share on other sites More sharing options...
Bixby Sayz Posted November 12, 2012 Author Share Posted November 12, 2012 I got it working now. Suddenly started working on it's own when I was cleaning up the code. Almost ready to share with the class. Just trying to find more than 10 minutes at a time to work on it. Quote Link to comment Share on other sites More sharing options...
LordJashin Posted November 12, 2012 Share Posted November 12, 2012 If try GetOuterWindow because calling ActivateWindow. Freddy's code...? If phail then wall bang head... Quote Link to comment Share on other sites More sharing options...