Checking a box in another application

W

Weaver2112

Hi, I am glad I came across this group. Nice content folks. I am
interested in finishing a little automation project. I have everything
figured out except for checking boxes in a treeview control. I am using
C# and using window handles to determine window location, move my
pointer, and do my clicking. I am running into an issue because one of
the forms I am interracting with has a treeview control built into it
with several sub items. I would like to check all the members of this
tree by scrolling through the items and clicking on them(or some such).

Does anyone have any suggestions or examples they could refer me to?
Anything would be appreciated. This is my first attempt at doing some
involved API programming so any pointers you can offer would be
sincerely appreciated.
Weaver
 
D

Dmytro Lapshyn [MVP]

Hi,

I'd suggest that you read MSDN docs on the TreeView common control messages
such as TVM_SELECTITEM and TVM_GETITEM. What you will most likely have to do
is to recursively walk through all the items in the treeview and sending a
message per each item that would make the item checked.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top