daninthemix
Registered User.
- Local time
- Today, 21:57
- Joined
- Nov 25, 2005
- Messages
- 41
Hey all,
I have a number of listboxes in a form who gather data about the main field in that form, so they are bound to queries etc.
The thing is, I have a routine that allows users to create new records, and in that instance the following code runs:
'[Forms]!customers.lstOpenCalls.RowSource = ""
'[Forms]!customers.lstClosedCalls.RowSource = ""
'[Forms]!customers.lstAssets.RowSource = ""
'[Forms]!customers.lstLogins.RowSource = ""
'[Forms]!customers.lstCarePacks.RowSource = ""
'[Forms]!customers.lstConfigs.RowSource = ""
'[Forms]!customers.Customer = NewCustomer
'[Forms]!customers.[Address 1].SetFocus
(without the 's of course). This is so that those listboxes don't have old data in for the new record. The problem of doing things this way is that the rowsource is then permanently changed and my queries are lost, as I found out to my annoyance! Is there a better way of doing this?
I have a number of listboxes in a form who gather data about the main field in that form, so they are bound to queries etc.
The thing is, I have a routine that allows users to create new records, and in that instance the following code runs:
'[Forms]!customers.lstOpenCalls.RowSource = ""
'[Forms]!customers.lstClosedCalls.RowSource = ""
'[Forms]!customers.lstAssets.RowSource = ""
'[Forms]!customers.lstLogins.RowSource = ""
'[Forms]!customers.lstCarePacks.RowSource = ""
'[Forms]!customers.lstConfigs.RowSource = ""
'[Forms]!customers.Customer = NewCustomer
'[Forms]!customers.[Address 1].SetFocus
(without the 's of course). This is so that those listboxes don't have old data in for the new record. The problem of doing things this way is that the rowsource is then permanently changed and my queries are lost, as I found out to my annoyance! Is there a better way of doing this?