Skip to Content
0
Former Member
Jun 04, 2008 at 09:48 PM

Clear data store on popup iView

52 Views

Hello gurus,

I have a popup Iview that I call repeately. I compile values in a data store each time I click on a row from a table. The problem I'm having is that I want to clear out the data store values each time I call the form to start fresh. The data store is populated each time a row of the table is selected. I also want to prevent the row from being selected automatically when the popup form is opened.

I have two fields in my data store

1. selectnum

2. Vendorkey

On the select event of the table that goes to the data store, I put a formula in the Vendorkey field for Assigned Value:

IF(STORE@selectnum>1,'',IF(CONTAINS(STORE@Vendorkey,@Vendor_key),STORE@Vendorkey,STORE@Vendorkey&(IF(LEN(STORE@Vendorkey)>0,';',''))&@Vendor_key))

This checks if the rows have already been selected, if so assign blank.

Otherwise, assign the incoming Vendor_key value and keep adding to it each time I select a row, separating each value with a semi colon.

The formula is not working and I don't know why. I think the select event from the table is not incrementing the "selectnum" value, or something.

Any thoughts or better work arounds? Does VC have something like a form initialize event???

Thank you!

John