rick207 Posted October 21, 2006 Share Posted October 21, 2006 Hi. I've got a Access DB, and want to automate filling data in form. Form has listview where I can choose an item. After choosing, other controls update with related data. What is the best way to pick up an item from this listview ? I've tried to send text to it (with success) and send {ENTER}, but didn't work. Any ideas Rick Link to comment Share on other sites More sharing options...
FuryCell Posted October 21, 2006 Share Posted October 21, 2006 Take a look at ControlListView(). It should give you pretty comprehensive control of the listview. However I'm not sure if it is compatible with MSAccess listviews as I don't have Acesss installed on this workstation. HKTunes:Softpedia | GoogleCodeLyricToy:Softpedia | GoogleCodeRCTunes:Softpedia | GoogleCodeMichtaToolsProgrammer n. - An ingenious device that turns caffeine into code. Link to comment Share on other sites More sharing options...
rick207 Posted October 21, 2006 Author Share Posted October 21, 2006 Thanks for clue, but isn't working. "GetItemCount" returns 0, "Select" sets @error=1 Link to comment Share on other sites More sharing options...
dabus Posted October 21, 2006 Share Posted October 21, 2006 (edited) MSOffice is a bunch of custom controls/toolbars. Most of the better/more complex automation functions will not work. Send works if you slow down the delay. Maybe you can find a way to open a "normal" box/dialog-window that can be controlled/works for you. Good luck. Edited October 21, 2006 by dabus Link to comment Share on other sites More sharing options...
rick207 Posted October 22, 2006 Author Share Posted October 22, 2006 It's not good news One question. Where exactly func "Send" sends data ? When I have active window with some controls, it's sent to that one which has focus ? Link to comment Share on other sites More sharing options...
randallc Posted October 22, 2006 Share Posted October 22, 2006 Hi, Is it a complex database, or can you do it with com commands (see udf from my sig)? Randall ExcelCOM... AccessCom.. Word2... FileListToArrayNew...SearchMiner... Regexps...SQL...Explorer...Array2D.. _GUIListView...array problem...APITailRW Link to comment Share on other sites More sharing options...
rick207 Posted October 22, 2006 Author Share Posted October 22, 2006 Thank you Randall, but I'm afraid your script isn't usefull for me. I can only work with GUI, have no access to tables Link to comment Share on other sites More sharing options...
rick207 Posted October 25, 2006 Author Share Posted October 25, 2006 Problem solved with "setfocus", "sleep" and send"{ENTER}". But the next problem arose. How to retrieve information from subform where data is in rows and columns (every row represents one record) ? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now