Confirmation Page Quesstion...

K

Ken D.

I have created an online form for our intranet using FrontPage 2003. The asp
form writes the data to SQL Server and a unique ID field is assigned on the
back end. The problem I am having is that when I generate a confirmation
page for the user, I can not pickup the the ID number as a confirmation
field. Is this possible? I would really like the user to have a unique
identifier for their request.

Any help would be appreciated.
 
S

Stefan B Rusynko

See http://www.aspfaq.com/show.asp?id=2174

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


|I have created an online form for our intranet using FrontPage 2003. The asp
| form writes the data to SQL Server and a unique ID field is assigned on the
| back end. The problem I am having is that when I generate a confirmation
| page for the user, I can not pickup the the ID number as a confirmation
| field. Is this possible? I would really like the user to have a unique
| identifier for their request.
|
| Any help would be appreciated.
 
K

Ken D.

Stephan,

Not being a programmer, that solution confused so I obtain the following
code and can't get it to work.

---------------
Dim db,rs,new_identity

--Create a database connection
Set db = .CreateObject("ADODB.connection")

--Execute the INSERT statement and the SELECT @@IDENTITY
Set rs = db.execute("INSERT INTO CommunityService (Region) " & _
"values (values,...);" & _
"select @@identity").nextrecordset

--Retrieve the @@IDENTITY value
new_identity = rs(0)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top