Browse Dialog - Filter options


Author
Message
StrataFrame Team
S
StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
Wait a second, I just remembered that we added the Searching event to the BrowseDialog.  In the event args of the event, we pass over the raw WhereStatement collection for the query to be executed.  You still cannot choose to have the values OR'ed together, but in this case, you could use the IN statemet type, so the value would be produced like:

SalesRep IN ('A', 'B')

which would accomplish the same thing for you.  So, you would just have to add a new WhereStatement to the collection with a type of WhereStatementTypeOptions.In and the Values ArrayList containing the "A" and "B."

StrataFrame Team
S
StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
Trent may correct me if I'm wrong, but I don't think that's currently possible with the BrowseDialog.  All search field values are AND'ed together, and anything you type in has to be able to be placed within a sql parameter.  So, if you wanted to include a field twice, that's fine, but it would have to be something like date < max AND date > min where 'date' is the same field.  So, if you want to have several values OR'ed together, such as in your example where you want to allow one or more of several explicit values, it's not possible at the moment.
Tim Dol
Tim Dol
StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)
Group: Forum Members
Posts: 340, Visits: 1.4K
How can I filter multiple values for a single field?

Say I am browsing the customer database and on the browse I have a hidden search field called 'SalesRep'. My database contains 10 records for SalesRep 'A', 5 records for SalesRep 'B' and 3 Records for SalesRep 'C'.  The current user is only allowed to view customer records for SalesRep 'A' or SalesRep 'B'.  I cannot show any customer records that belong to SalesRep 'C'.

Can my search return all records for SalesRep 'A' and 'B' ?  How would you set 'MyFilterValue' to produce this result?. Can I use the same filter logic as I would in the business object filter....  SalesRep = 'A' or SalesRep = 'B'

Thanks

Tim

Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
I think there are a number of different assumptions going on within this post.  First, you CAN search on a hidden field.  So it is entirely possible to add a field to the browse dialog that is never presented to the end-user in which you provide a value programmatically.  You would just set visibility of the search field to False within code or the designer:

MyBrowse.SearchFields(0).Visible = False
MyBrowse.SearchFields(0).InitialSearchValue = "MyFilterValue"

Now, as for repopulating a combo within the BrowseDialog once it has been loaded off of the value of another combo-box, this cannot be done at the moment.

Greg McGuffey
Greg McGuffey
Strategic Support Team Member (3.4K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
I would have sworn they added the ability to use a hidden field in a search with the last release.
Edhy Rijo
E
StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)
Group: StrataFrame Users
Posts: 2.4K, Visits: 23K
Ivan George Borges (11/24/2007)
Would this be a workaround for the time being? Or just a lot of nonsense? Blush

Hi Ivan,

It is not a nonsense, but it would be very ugly and not user friendly to the end user.  In my case the DB has several fields to do the search, and only 2 of those are related or depend on each other, but the user can select any of the other fields, and I don't see how one would separate those fields and add a 2nd dialog to handle the situation.

Edhy Rijo

Ivan George Borges
Ivan George Borges
Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)
Group: StrataFrame MVPs
Posts: 1.9K, Visits: 21K
Hi guys.

It is just a thought... what if 2 Browse Dialogs where dropped on the form? The first one could search the parent, and then the second one could have the parent PK set with the current parent value, and not visible.

Would this be a workaround for the time being? Or just a lot of nonsense? Blush

Edhy Rijo
E
StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)StrataFrame VIP (4.7K reputation)
Group: StrataFrame Users
Posts: 2.4K, Visits: 23K
Hi Tim,

That is a feature I also requested previously, see my posts at: http://forum.strataframe.net/Topic12011-7-1.aspx

So far, there is no way to filter a combo based on data selected in another object in the Browser Dialog. 

I hope they can add this feature soon!!!

Edhy Rijo

Tim Dol
Tim Dol
StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)StrataFrame User (434 reputation)
Group: Forum Members
Posts: 340, Visits: 1.4K
In our CRM package we can assign sales reps to sales managers. When a sales manager looks at a job listing or account listing they can only see the records for his/her own sales reps.

I need to build a sales manager browse dialog and need to hide the sales rep field, which I can do, but I need to supply a filter behind the scenes such as SalesRep = 'A' or 'B' or 'C' etc.. 

Can I do something like this in the current version?  If not, do you plan on adding this sometime soon?

Thanks,

Tim

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search