Wrox Programmer Forums
|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 29th, 2007, 01:53 PM
Authorized User
 
Join Date: Jan 2007
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default Help with register.asp

Hi

I need some help with a register.asp page on http://www.business-youthlink.co.za/register.asp.
The database.mdb is allocated and all cells are binded.

Question:

-How do i make sure the details are captured and at the same time it goes to the next record.
under i put one piece off
register.asp

<%@LANGUAGE="VBSCRIPT"%>

<%
Dim Recordset1
Dim Recordset1_cmd
Dim Recordset1_numRows

Set Recordset1_cmd = Server.CreateObject ("ADODB.Command")
Recordset1_cmd.ActiveConnection = MM_nafcocyouth_STRING
Recordset1_cmd.CommandText = "SELECT 10, 10100, 101200, 200, cc, cellphone, contacttel, datenamechanged, descriptofbusiness, designation, emailaddress, emailadressee, fax, female, govtdept, homelanguage, ID, idno, industry, male, name, namet, ngo, ownership, phisicaladdress, plubliccom, postaladdres, postalcode, preferedlanguage, prevcompanyname, publishdesig, publishdesig1, publishemail, publishemail1, regdate, regno, section21, sector, soleowner, surnamet, taxregno, tel, title, tradingas, trust, typeofbusiness, unknow, vatregno FROM companyprofile"
Recordset1_cmd.Prepared = true

Set Recordset1 = Recordset1_cmd.Execute
Recordset1_numRows = 0
%><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 //EN">

<HTML>

<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<style type="text/css">
<!--
#Layer26 { position:absolute;
    width:479px;
    height:55px;
    z-index:11;



and nafcocyouth.asp from the connection folder

<%
Dim MM_nafcocyouth_STRING
MM_nafcocyouth_STRING = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source= D:\somewhere\business-youthlink.co.za/somewhere/somewhere/database.mdb"
%>

if somebody please could help me .
i am looking now for help already 2 months and i think this forum
could help

[email protected]





 
Old January 29th, 2007, 03:15 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

...What kind of problems are you having.

================================================== =========
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
 
Old January 30th, 2007, 04:01 AM
Authorized User
 
Join Date: Jan 2007
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

dparsons

I would appreciate if you could tell me how to do it,
not you doing it for me

thx in advance

 
Old January 30th, 2007, 09:29 AM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

That is my signature, hence it is attached to all of my posts. So, if you would like me to help you, answer my question. Posting your code does me next to no good if you can't tell me what kind of problems you are having.

================================================== =========
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
 
Old January 30th, 2007, 10:46 AM
Authorized User
 
Join Date: Jan 2007
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I understand mr.

The problem that i am facing is the following one.

As stated the register.asp from http://www.business-youthlink/register.asp

does find the database, all cells are binded page to database.

My question is as follow:

How do i instruct the page to hold or add the details onto the database

and after doing this to go to one other 'next' record?

I think this is it mr.dparsons.

I apologise for the maybe wrong exprssion from my site,

but i did not mean anything with it, i now after i was looking onto this
forum that somebody could help me here.

Thx in advance

[email protected]

 
Old January 30th, 2007, 11:55 AM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

If by 'hold' you mean NOT manipulate the data in the database you would do nothing since simply pulling the data from the database does not change it in any way.

To add the information you would need to provide a button that, when clicked, would INSERT the data into the database. (Via a SQL Query or RS.AddNew)

Lastly, as far as fetching records, you could set up paging to allow a user to iterate through all of the records in the database, although I don't find that desireable.

Unfortunately I cannot view your register page as my proxy is rejecting the site, so, that is the best I can tell you with what you have told me and with not being able to see your site.

================================================== =========
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
 
Old January 30th, 2007, 12:45 PM
Authorized User
 
Join Date: Jan 2007
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Mr. dparsons,


Yes you,re right saying Not to manupilate the details only to capture,

so if i understand it well i need to put a buttom whoes linked to a SQL query

maybe like this "Insert RS.AddNew =INSERT 10, 10100, 101200, 200, cc, cellphone, contacttel, datenamechanged, descriptofbusiness, designation, emailaddress, emailadressee, fax, female, govtdept, homelanguage, ID, idno, industry, male, name, namet, ngo, ownership, phisicaladdress, plubliccom, postaladdres, postalcode, preferedlanguage, prevcompanyname, publishdesig, publishdesig1, publishemail, publishemail1, regdate, regno, section21, sector, soleowner, surnamet, taxregno, tel, title, tradingas, trust, typeofbusiness, unknow, vatregno FROM companyprofile"

I gonna trail this mr. and who knows maybe it works, if i understand it right, i mean.

Mr dparsons you are the first person who is given me a clue, thanks for that.

I hope you can see the website i am busy making may be to give you professional comments.

If i have to setup paging, i was thinking maybe to exlude a database, is it possible to send the page with the details to a email addres with or without iterating , or am i talking nonsens?


Thx

[email protected]

PS I have to go home now its getting dark, South Africa is not save in the night.
First thing tomorrow i going to trail to put that buttom with the,hopefully right query, think i going to come back anyway working or not

thanks again

 
Old January 30th, 2007, 03:02 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

You will either do an INSERT OR rs.addnew so your above SQL Query is incorrect.

SQL:
INSERT INTO [table](<columns>) VALUES(<values>)

RS.AddNew:
rs.addnew
rs(<columnname>) = value
rs.update

And i do not know what you mean by this:
If i have to setup paging, i was thinking maybe to exlude a database, is it possible to send the page with the details to a email addres with or without iterating , or am i talking nonsens?

================================================== =========
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
 
Old January 31st, 2007, 04:22 AM
Authorized User
 
Join Date: Jan 2007
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi dparsons,

I wanted to say that maybe there is a way to exlude the database, aldo i wich to make it to work with the database,and with a click on a buttom to send the
page to a emailadres.
Maybe this could be easier but for now let me trail to insert as you recommend.

THX


 
Old January 31st, 2007, 05:21 AM
Authorized User
 
Join Date: Jan 2007
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Mr.dparsons

Maybe one other thing if you still availeble.
How do i link the 'submit' button with the INSERT query?

THX






Similar Threads
Thread Thread Starter Forum Replies Last Post
Register namespace using ASP deean Classic ASP Basics 0 June 16th, 2008 09:23 PM
ASP.NET not register under IIS evridiki ASP.NET 2.0 Basics 3 February 22nd, 2006 04:04 PM
Ch 15 Register.asp query daveyarwood BOOK: Beginning ASP 3.0 0 July 16th, 2005 12:52 PM
Register Globals Off cmiller Beginning PHP 4 August 18th, 2003 05:21 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.