|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hi,
I have a form with close button and printout button. When i click close button the form closes and returns back to switchboard. That is fine but when i click the printout button the current form prints but when i close the form it takes me to the forms objects (where we have differnt forms under form object screen). I want it to return to switchboard rather than the form object. The following is the code that runs behind the print button. Private Sub Command65_Click() On Error GoTo Err_Command65_Click Dim stDocName As String Dim MyForm As Form stDocName = "Wire Reconciliation Frm" Set MyForm = Screen.ActiveForm DoCmd.SelectObject acForm, stDocName, True DoCmd.PrintOut DoCmd.SelectObject acForm, MyForm.Name, False Exit_Command65_Click: Exit Sub Err_Command65_Click: MsgBox Err.Description Resume Exit_Command65_Click End Sub Any advice Dwight |
![]() |
| Viewing: Dev Articles Community Forums > Databases > Microsoft Access Development > Printout button closes the form? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|