Re: How to lock information
- From: "HekaEnt via AccessMonster.com" <u30967@uwe>
- Date: Wed, 24 Jan 2007 14:09:14 GMT
Ok, i finally got it in the correct location and one is working, and the
other is not. it if giving me this error (image attached. attached is a image
showing my code exactly in the application.
----------
Private Sub Form_AfterUpdate()
If Not IsNull([CTM - Setup]) Then
[CTM - Setup].Locked = True
Else
[CTM - Setup].Locked = False
End If
End Sub
Private Sub Form_Current()
If Not IsNull([CTM - Setup]) Then
[CTM - Setup].Locked = True
Else
[CTM - Setup].Locked = False
End If
End Sub
----------
www.hekaent.com/Customers/P/PolyCast/images/error2465.jpg
www.hekaent.com/Customers/P/PolyCast/images/scriptError.jpg
Al Campagna wrote:
I think you haven't entered the code where it needs to be placed.
You don't enter the code into the "text box" beside the OnCuurent event, you open the
code "module" for the OnCurrent event, and put the code in there. But in Visiual Basic
I can't be sure...
Here's how it's done in Visiual Studio... should be the same, or very close...
*First, delete anything you have in the OnCurrent textbox...*
Now try Double clicking the OnCurrent text box on the right, or the OnCurrent name box
on the left.
Does a module open up?
Here's an example for causing a Beep on FormActivated...
I double click the text box to the right of the Activated event
This appears...
Private Sub Form1_Activated(ByVal sender As System.Object, ByVal e As System.EventArgs)
Handles MyBase.Activated
End Sub
Now I place my code between those lines...
Private Sub Form1_Activated(ByVal sender As System.Object, ByVal e As System.EventArgs)
Handles MyBase.Activated
Beep()
End Sub
Now when I run the form, I get a "Beep" sound
here is the code i am using and i am still getting that error concerning the[quoted text clipped - 45 lines]
macro previously posted on image.
www.hekaent.com/Customers/P/PolyCast/images/onCurrent.bmp
www.hekaent.com/Customers/P/PolyCast/images/afterUpdateError.bmp
--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/Forums.aspx/access-forms/200701/1
.
- Follow-Ups:
- Re: How to lock information
- From: Al Campagna
- Re: How to lock information
- References:
- How to lock information
- From: HekaEnt
- Re: How to lock information
- From: Al Campagna
- Re: How to lock information
- From: HekaEnt via AccessMonster.com
- Re: How to lock information
- From: HekaEnt via AccessMonster.com
- Re: How to lock information
- From: Al Campagna
- Re: How to lock information
- From: HekaEnt via AccessMonster.com
- Re: How to lock information
- From: Al Campagna
- Re: How to lock information
- From: HekaEnt via AccessMonster.com
- Re: How to lock information
- From: Al Campagna
- How to lock information
- Prev by Date: Re: LinkMaster>LinkChild problem
- Next by Date: filter by combo boxes in a form for a report
- Previous by thread: Re: How to lock information
- Next by thread: Re: How to lock information
- Index(es):
Relevant Pages
|