RichO
Registered Yoozer
- Local time
- Today, 16:49
- Joined
- Jan 14, 2004
- Messages
- 1,036
ChrisO,
Did you get the PM I sent you?
I had explained the whole problem about why I was having trouble getting the forms and everything else into a file to send to you. I spent about an hour on it and gave up because there was always something else it was looking for. Also the tables are stored in SQL server and I was getting errors in trying to convert to Access 97.
Could this same task be accomplished by cycling through the recordset and summing the check box values?
I tried this but it looks like it only catches the first record in the recordset...
Dim db As Database
Dim rs As Recordset
Dim sql As String
Dim chex As Integer
Set db = CurrentDb
sql = "SELECT Check_Box FROM tb_Promo_Artist_Quotes WHERE Promo_ID = " & Me.Promo_ID
Set rs = db.OpenRecordset(sql)
If Not rs.EOF Then
chex = chex + rs!Check_Box
End If
rs.Close
Set rs = Nothing
Set db = Nothing
If chex <> 0 Then DoCmd.OpenReport "Promotion Schedules", acPreview, , "Promo_ID = " & Me.Promo_ID
Maybe you can tell me what is missing here...
Thanks again.
Did you get the PM I sent you?
I had explained the whole problem about why I was having trouble getting the forms and everything else into a file to send to you. I spent about an hour on it and gave up because there was always something else it was looking for. Also the tables are stored in SQL server and I was getting errors in trying to convert to Access 97.
Could this same task be accomplished by cycling through the recordset and summing the check box values?
I tried this but it looks like it only catches the first record in the recordset...
Dim db As Database
Dim rs As Recordset
Dim sql As String
Dim chex As Integer
Set db = CurrentDb
sql = "SELECT Check_Box FROM tb_Promo_Artist_Quotes WHERE Promo_ID = " & Me.Promo_ID
Set rs = db.OpenRecordset(sql)
If Not rs.EOF Then
chex = chex + rs!Check_Box
End If
rs.Close
Set rs = Nothing
Set db = Nothing
If chex <> 0 Then DoCmd.OpenReport "Promotion Schedules", acPreview, , "Promo_ID = " & Me.Promo_ID
Maybe you can tell me what is missing here...
Thanks again.