Friday, March 9, 2012

Open a blank or new record set code needed.

I have an access 2003 Data access page published to the web that gets its data successfully from an MS SQL 2005 server. I need the "page when it opens" to display a new / blank record (not the first record in the table as it does by default) any pointers would be nice thanks Pete...Hi,

Im not sure if this is the best forum for this question as you say the page gets its data successfully from an MS SQL 2005 Database server.

Sorry to not be able to assist more.
|||

If you connect a table through a linked table to SQL Server, you will have to specify a primary key on the Access side, otherwise Access might not know how to update / insert new records.

HTH, Jens K. Suessmeyer.


http://www.sqlserver2005.de

|||

Thank you for your input.

I don’t want to sound confusing although I am confused! Here goes. I built the Access database with Access 2007, connecting to a 2005 SQL server. The database tables all have primary keys. The forms all function fine and I used the code in them “d0cmd on open goto newrecord” and the forms open ready for a new record concealing existing data from the users.

I then used access 2003, to create data access pages and publish them to our web site. (nice trick ha?) So far this works fine usingthe record navigator and custom built controls I can ad / edit and create new records. What I need to solve is, when I open a data access page over the internet the first record is displayed. I need the page to open and be ready to accept a new record showing all blank fields and not existing records.

The data assess page requires different coding to accomplish this than the forms and this is where I am getting lost?

|||I found the solution this was easy, open the dataaccess page in design view in access, select edit / page and set the can edit properties to false, the page opens to a blank record and will not reveal other records, just what i wanted.

No comments:

Post a Comment