A strange error

  • Thread starter Thread starter Dwayne Conyers
  • Start date Start date
D

Dwayne Conyers

We have a form tied to a table in our database. When creating a new record,
we get an error that says:

"Index or primary key cannot contain a null value"

The form has the primary key (ID) field in a hidden/invisible textbox since
that field is an autonumber. Not sure why we are getting this error.
We've built other forms the same way...
 
-----Original Message-----
We have a form tied to a table in our database. When creating a new record,
we get an error that says:

"Index or primary key cannot contain a null value"

The form has the primary key (ID) field in a hidden/invisible textbox since
that field is an autonumber. Not sure why we are getting this error.
We've built other forms the same way...

--
dwacon
www.dwacon.com


.
unhide the autonumber field and make it visable
you can still hide it by making tabstop to no and placing
it under another textbox
 
Hi Dwayne,

If you create a fresh new form based on the same table, does the issue
occur? If you open the table and add the record directly, the problem
occurs?

Otherwise, would you please post the table structure?


Sincerely,

Alick Ye, MCSD
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
|
| We have a form tied to a table in our database. When creating a new
record,
| we get an error that says:
|
| "Index or primary key cannot contain a null value"
|
| The form has the primary key (ID) field in a hidden/invisible textbox
since
| that field is an autonumber. Not sure why we are getting this error.
| We've built other forms the same way...
|
| --
| dwacon
| www.dwacon.com
|
|
|
 
Looks like we found the probolem... the ID was wrong data type, should have
been Autonumber.

d.c.
 
Hi Dwayne,

Glad to hear you have found the cause :- )


Sincerely,

Alick Ye, MCSD
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

--------------------
| Reply-To: "Dwayne Conyers" <[email protected]>
| X-Tomcat-NG: microsoft.public.access.forms
|
| Looks like we found the probolem... the ID was wrong data type, should
have
| been Autonumber.
|
| d.c.
|
|
| | > Hi Dwayne,
| >
| > If you create a fresh new form based on the same table, does the issue
| > occur? If you open the table and add the record directly, the problem
| > occurs?
| >
| > Otherwise, would you please post the table structure?
| >
| >
| > Sincerely,
| >
| > Alick Ye, MCSD
| > Microsoft Online Partner Support
| >
| > Get Secure! - www.microsoft.com/security
| > This posting is provided "as is" with no warranties and confers no
rights.
| >
| > --------------------
| > |
| > | We have a form tied to a table in our database. When creating a new
| > record,
| > | we get an error that says:
| > |
| > | "Index or primary key cannot contain a null value"
| > |
| > | The form has the primary key (ID) field in a hidden/invisible textbox
| > since
| > | that field is an autonumber. Not sure why we are getting this error.
| > | We've built other forms the same way...
| > |
| > | --
| > | dwacon
| > | www.dwacon.com
| > |
| > |
| > |
| >
|
|
|
 
Back
Top