Echo On: "NO" (1 Viewer)

tanski811

Registered User.
Local time
Yesterday, 22:01
Joined
Apr 8, 2005
Messages
24
Where and how do I write in this code that is a command button to open up a form to set the Echo off. I know how to do it in a marco but not how to write it in VB code.

Below is the VB code for my "open form" button...

Private Sub LookUpOpenFormButton_Click()
On Error GoTo Err_LookUpOpenFormButton_Click

Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "frm_Account"

stLinkCriteria = "[ID]=" & Me![LookUpAccount]
DoCmd.OpenForm stDocName, , , stLinkCriteria
DoCmd.Close acForm, "Switchboard Lookup"
Exit_LookUpOpenFormButton_Click:
Exit Sub

Err_LookUpOpenFormButton_Click:
MsgBox Err.Description
Resume Exit_LookUpOpenFormButton_Click

End Sub
 

MarkK

bit cruncher
Local time
Yesterday, 22:01
Joined
Mar 17, 2004
Messages
8,186
Echo False
' Screen writes suspended
Echo True
' Screen writes re-enabled
 

meboz

Registered User.
Local time
Today, 15:01
Joined
Aug 16, 2004
Messages
71
Ive found that every time I have a line of code 'Docmd.echo false' i ALWAYS get an error.

So I left it out.

When code stops running echo seems toreturn to normal. Just some observations ive made, i dont know the ins-and-outs of echo very well.
 

MarkK

bit cruncher
Local time
Yesterday, 22:01
Joined
Mar 17, 2004
Messages
8,186
Not sure how much difference it makes, but I'm talking about Application.Echo, not DoCmd.Echo.
 

Users who are viewing this thread

Top Bottom