WinBatch® Technical Support Forum

All Things WinBatch => WinBatch => Topic started by: bmclellan on April 15, 2020, 02:34:48 PM

Title: ReportView setFocus and Select
Post by: bmclellan on April 15, 2020, 02:34:48 PM
Hello,

I have a report view that has a few pages in it. I am entering a number to do a lookup, then setting the focus and selecting the item.
When complete, the line is highlighted, however I need to scroll down the item list to find it, it doesn't just jump to that spot in the list.

Has anyone ran across this before?

I've tried both orders just for kicks
   DialogControlState(Handle,"rv_Stores",@dcsSetFocus,'')
   DialogControlSet(Handle,"rv_Stores",@dcSelect,rv_Stores[result,0])


Thanks!
Barry

Title: Re: ReportView setFocus and Select
Post by: JTaylor on April 15, 2020, 07:19:00 PM
See if DialogControlSet() option @dcScroll  (10) does what you need.

Jim
Title: Re: ReportView setFocus and Select
Post by: bmclellan on April 16, 2020, 06:06:02 AM
That worked!

Jim, can't thank you enough for all your help with my last 3 questions! I couldn't have completed my tasks without you!


Have a great day!
Barry
Title: Re: ReportView setFocus and Select
Post by: JTaylor on May 01, 2020, 05:15:21 PM
Something I ran across that might interest you and is related to the suggestions around data sets and populating ReportView.   If you use a Persisted recordset, which I think was suggested by Stan.   You would find the  "Filter" option useful.   You can open the entire recordset and then apply a filter like below.  If you use a Shaped set you can apply filters to both recordsets.    Examples in Tech DB.   Thank Stan if you find it useful.

     myRS.Filter = "id > 1000 and id < 2000


Jim