Hi All, hoping you can help.
I have an incident database where we keep track of system issues that result in a tech having to be called in during off hours (which is interestingly know as a "callout" not a "callin"
.
The database is very simple, one table with all the info about each callout. There are four different networks, I have the save button event on the form send out a text version of a very simple report that encapsulates the callout. Here's the code.
<snip>
Private Sub cmdSAVE_Send_Click()
On Error GoTo Err_cmdSAVE_Send_Click
Dim stDocName As String
Dim stSystem As String
stDocName = "new_callout"
stSystem = Forms!frmRadio_Callout!cboNetwork
If stSystem = "IRNE" Then
DoCmd.SendObject acReport, stDocName, acFormatTXT, "someone@somewhere.com", , , "IRNE Callout Incident", "An incident has been added to the Callout Report Database. Click '\\A network drive\callout.mdb' to see the record.", False
ElseIf stSystem = "800" Then
DoCmd.SendObject acReport, stDocName, acFormatTXT, "someone@somewhere.com", , , "800 MHz System Call Out Incident", "An incident has been added to the Callout Report Database. Click '\\A network drive\callout.mdb' to see the record.", False
ElseIf stSystem = "Video" Then
DoCmd.SendObject acReport, stDocName, acFormatTXT, "someome@somewhere.com", , , "Video Callout Incident", "An incident has been added to the Callout Report Database. Click '\\A network drive\callout.mdb' to see the record.", False
ElseIf stSystem = "INET" Then
DoCmd.SendObject acReport, stDocName, acFormatTXT, "someone@somewhere.com", , , "INET Callout Incident", "An incident has been added to the Callout Report Database. Click '\\A Network Drive\callout.mdb' to see the record.", False
End If
Exit_cmdSAVE_Send_Click:
Exit Sub
Err_cmdSAVE_Send_Click:
MsgBox Err.Description
Resume Exit_cmdSAVE_Send_Click
End Sub
</snip>
I have a filter on the report set to a non-visible control called txtID on the form. The record source is "qryCallOut" the filter for the report is "ID = Forms!frmRadio_Callout.txtID" When the user clicks the save button the report is created and sent via the code above. txtID is an auto-generated key field.
This works today, I test it from my computer and logged on as another user at another computer, I'll think everything is ok but then tomorrow I'll be cc'd on one of these callout reports and it will be just the labels on the report I created and no data. I'm hoping someone can help me figure this out.
I'm using Access97.
Thanks,
PenelopeC
~~~>-/O~~~~~swimming right along
I have an incident database where we keep track of system issues that result in a tech having to be called in during off hours (which is interestingly know as a "callout" not a "callin"
The database is very simple, one table with all the info about each callout. There are four different networks, I have the save button event on the form send out a text version of a very simple report that encapsulates the callout. Here's the code.
<snip>
Private Sub cmdSAVE_Send_Click()
On Error GoTo Err_cmdSAVE_Send_Click
Dim stDocName As String
Dim stSystem As String
stDocName = "new_callout"
stSystem = Forms!frmRadio_Callout!cboNetwork
If stSystem = "IRNE" Then
DoCmd.SendObject acReport, stDocName, acFormatTXT, "someone@somewhere.com", , , "IRNE Callout Incident", "An incident has been added to the Callout Report Database. Click '\\A network drive\callout.mdb' to see the record.", False
ElseIf stSystem = "800" Then
DoCmd.SendObject acReport, stDocName, acFormatTXT, "someone@somewhere.com", , , "800 MHz System Call Out Incident", "An incident has been added to the Callout Report Database. Click '\\A network drive\callout.mdb' to see the record.", False
ElseIf stSystem = "Video" Then
DoCmd.SendObject acReport, stDocName, acFormatTXT, "someome@somewhere.com", , , "Video Callout Incident", "An incident has been added to the Callout Report Database. Click '\\A network drive\callout.mdb' to see the record.", False
ElseIf stSystem = "INET" Then
DoCmd.SendObject acReport, stDocName, acFormatTXT, "someone@somewhere.com", , , "INET Callout Incident", "An incident has been added to the Callout Report Database. Click '\\A Network Drive\callout.mdb' to see the record.", False
End If
Exit_cmdSAVE_Send_Click:
Exit Sub
Err_cmdSAVE_Send_Click:
MsgBox Err.Description
Resume Exit_cmdSAVE_Send_Click
End Sub
</snip>
I have a filter on the report set to a non-visible control called txtID on the form. The record source is "qryCallOut" the filter for the report is "ID = Forms!frmRadio_Callout.txtID" When the user clicks the save button the report is created and sent via the code above. txtID is an auto-generated key field.
This works today, I test it from my computer and logged on as another user at another computer, I'll think everything is ok but then tomorrow I'll be cc'd on one of these callout reports and it will be just the labels on the report I created and no data. I'm hoping someone can help me figure this out.
I'm using Access97.
Thanks,
PenelopeC
~~~>-/O~~~~~swimming right along