Newsgroups : Borland : borland.public.delphi.nativeapi.win32 : 2007 Apr : Stuffing a string into a 3rd party app's field
| Subject: | Stuffing a string into a 3rd party app's field |
| Posted by: | "Jeremy" (jeremy-nospam@ninprodata.com) |
| Date: | Thu, 12 Apr 2007 10:10:43 |
I see from posts in 2/2007 that JD and Remi both have expertise in this
area, hence this post.
I have a D7 app that needs to stuff data into a few fields of another app.
I don't have source for the other app, and cannot control anything about it,
other than to insist that the correct form be displayed.
The problem I'm having is, I'd like my app to remember the form and a few
fields from the other app, so the user can do a setup once, and forever more
not have to think about this (unless the other app changes).
For a long time, I suffered from the misconception that GetDlgItemID would
return an invariant value (invariant across instances of the target), but I
can demonstrate that this is not the case. I can store the form caption and
classname for the foreign app, and that seems to get me started each
session. The next step seems to be to remember the top-left corner of the
target textboxes and try to get a whndl from that. But I'm confounded by
z-axis issues. I'm thinking that the other developer has overlaid textboxes
at the same location. Really, I need a unique, invarian ID of some kind,
but can't find one.
Any suggestions?
Jeremy