Rabu, 01 Oktober 2014

Re: [MS_AccessPros] option group error message

 

Jessica-


What is "Psych"?  A field in the Record Source?  A control on the form?

By the way, the Value property is the default for all controls, so you don't need to state that.  But you should qualify the name to make it clear that you're accessing something on the form or in the Record Source rather than a variable declared elsewhere.  It's really simple to put Me. in front of any reference to a control or field to make it crystal clear.  I suspect there are more than one "Psych" in the form's environment, so maybe you're not setting what you thing you are!

John Viescas, Author
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications 
SQL Queries for Mere Mortals 
(Paris, France)




On Oct 1, 2014, at 9:28 PM, hobackjessica@yahoo.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:

 I have added several option groups to a form and have written the code to "translate" the option value from a number value to yes, no, n/a or whatever the case may be.  This has been working very well until now.  One option group is giving me " Run-time error '3032' Cannot perform this operation".  Here's the code:

 

Private Sub Frame332_AfterUpdate()

Select Case Frame332.Value
    Case 1
        Psych.Value = "Yes"
    Case 2
        Psych.Value = "No"
End Select

End Sub

 

This looks identical (with the exception of the field name of course) to all of the other option groups I have.  Can anyone see my problem?

 

Thanks!

Jessica


__._,_.___

Posted by: John Viescas <johnv@msn.com>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (5)

.

__,_._,___

Tidak ada komentar:

Posting Komentar