Issue 75436 - Filtering form records by using an unbound control on the form
Summary: Filtering form records by using an unbound control on the form
Status: CONFIRMED
Alias: None
Product: Base
Classification: Application
Component: code (show other issues)
Version: OOo 2.1
Hardware: All All
: P3 Trivial with 2 votes (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-03-15 21:52 UTC by ftoth
Modified: 2013-08-07 15:45 UTC (History)
2 users (show)

See Also:
Issue Type: ENHANCEMENT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description ftoth 2007-03-15 21:52:41 UTC
When using forms you can apply autofilters, and formfilters, but you can not 
create a custom filter easily to f.i. enter a start and end date.

It would be *very* usefull to be able to add unbound controls on a form (say 
StartDate and EndDate) and then have the datasource on the form use those 
controls to filter the records, i.e. 

select * from atable where Date > :StartDate and Date < :EndDate

It appears to my from the SDK (see DevelopersGuide chapter 13.5.1 section 
Parameters) that this can be done by adding the controls to some list of 
listeners (using com.sun.star.form.XDatabaseParameterBroadcaster) so that they 
get resolved when the query runs (done by 
com.sun.star.form.XDatabaseParameterListeners).

However, it is unclear what code to use to do that, and the SDK mentions at 
this time it can not be done from Basic.

To me it seems that unbound controls on the form should *always* by listening 
to queries that require input. Why else would they be there?

Also it is not clear (to me) from the SDK if the unbound control is listening 
to queries run by other forms or if a special syntax is needed to access a 
control on another form (like MS Access does).
Comment 1 marc.neumann 2007-03-16 10:27:32 UTC
HI,

I reassign this issue to the User Experience team for evaluating.

Bye Marc
Comment 2 ftoth 2007-04-06 22:14:35 UTC
In the mean while, is there a code snippet or example available somewhere that I
can use to get this working?

Thanks,

Ferry