Results 1 to 6 of 6
  1. #1
    Join Date
    Jun 2009
    Posts
    95

    Unanswered: Creating New Record on Subform Error

    On my subform, I am trying to add a record, and when I start typing in the first field, I receive this message after the first character is entered:

    You can't assign a value to this object.
    *The object may be a control on a read-only form.
    *The object may be on a form that is open in Design view.
    *The value may be too large for this field.

    A little info about the subform, the first field is an autonumber, the others are just generic fields (business name, address, etc).

    I start typing the first field, after autonumber, and it displays that message.

    Any idea why this is happening?

    Thanks,
    CT

  2. #2
    Join Date
    May 2005
    Posts
    1,191
    Is the rowsource for the subform a table or a query? If it's a query I don't think you can just start typing, as it's derived data not tabular data.
    Me.Geek = True

  3. #3
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Check your default values. Sometimes this happens when a default value for a control is invalid for the field. Also check your Link Master/Child fields for the subform. They need to be the Primary Key for the master field and foreign key for the child.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  4. #4
    Join Date
    Jun 2009
    Posts
    95
    The rowsource for the subform is a table.

    I checked the default values, they are fine. Also the Link Master/Child fields are fine as well.

    Any other ideas?

    Thanks,
    CT

  5. #5
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    What code do you have in your form? Is there something trying to set a value to something BeforeInsert or AfterInsert... or OnChange of the field you are entering into?

    Bit hard to say -- it's all guesswork atm.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  6. #6
    Join Date
    Sep 2006
    Location
    Surrey, UK
    Posts
    994
    Provided Answers: 2
    You're not trying to type in the AutoNumber field, are you? That's what your first post implies.
    10% of magic is knowing something that no-one else does. The rest is misdirection.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •