473,809 Members | 2,951 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Asp using Vb script not working with access database

3 New Member
Hello everyone

i have a problem with my db connection i paste code below please check anyone where i am wrong its very urgent please any one help me!!!!!
and i am working offline using local iis server just check

Thanks
Ravi kale


<%@LANGUAGE="VB SCRIPT"%>
<!--#include file="Connectio ns/ravi.asp" -->
<%
Dim raj
Dim raj_numRows
'Dim recordset

Set raj = Server.CreateOb ject("ADODB.Rec ordset")
raj.Activeconne ction = MM_ravi_STRING
raj.Source = "SELECT * FROM employee"
raj.CursorType = 0
raj.CursorLocat ion = 2
raj.LockType = 1
raj.Open()
raj_numRows = 0
%>

<script language="VBScr ipt" type="text/VBScript">
set.cnn = Server.CreateOb ject("ADODB.Con nection")
open.connection
cnn.open("Drive r={MicrosoftAcc essDriver(*.mdb )};DBQ=D:\trupt i.mdb;Uid=sa;Pw d=sa;")
"Driver = {MicrosoftAcces sDriver(*.mdb)} ;DBQ=D:\trupti. mdb;Uid=sa;Pwd= sa;"
open.recordset
set rs = server.CreateOb ject("ADODB.Rec ordset")
strSQL= "select * from employee"
rs.open strSQL,cnn,3,2
insert into employee('First _name','Last_na me','Telephone' ,'Email','Comme nt')
values("&txtfir st_name.txt&"," &txtlast_name.t xt&","&txttelep hone.number&"," &txtEmail.memo& ","&txtComment. txt&")
if NOT rs.eof Then
while NOT rs.EOF
rs.movenext
wend
end if

</script>
<html>
<head>
<Body>
<FORM action="test.as p"FORM METHOD="post" name=test.asp Actionvar=add">

<p>First_name
<INPUT TYPE="text" NAME="First_nam e">
<BR>
Last_name
<INPUT TYPE="text" NAME="Last_name ">
<BR>
Telephone
<INPUT TYPE="text" NAME="Telephone ">
<BR>
Email
<INPUT TYPE="text" NAME="Email">
<BR>
Comment
<INPUT TYPE="text" NAME="Comment">
<BR>
<INPUT name="add" TYPE="submit" id="insert" VALUE="Insert">
</p>
</FORM>
</html>
</head>
</Body>

<%
raj.Close()
Set raj = Nothing
%>
May 16 '07 #1
1 1752
JackT
1 New Member
I have found answers to almost every connection string problem I have ever had at http://www.connections trings.com/
May 16 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
1936
by: Bobby | last post by:
Hello everyone I have a question. The school I am working for is in the beginning process of having a webpage that will direct students to download there homework and be able to view there info like test scores and etc(the homework and info page will reside on our webservers at the school on the local intranet network). Now what I need is a way for the students to go to a login page and when logging in will be automatically directed to...
4
12684
by: chris.dunigan | last post by:
I'm looking for an example of how to execute an existing DTS­ package from an ASP (VB)script and would appreciate any and all response. ­I don't even know if it's possible Thanks - Chuck Gatto Dan Guzman Apr 27 2000, 12:00 am show options
2
4761
by: Nasir Wasim | last post by:
How can Access DIV Properties in Script while using Netscape 7.2. I want to use the div id with it's Visibility and left propertyin script but it's not working :-( Main File : ----------- <div id="index" style="position:absolute; width:200px; height:115px; z-index:1; left:-400px; top: 286px visibility:false;">
121
10202
by: typingcat | last post by:
First of all, I'm an Asian and I need to input Japanese, Korean and so on. I've tried many PHP IDEs today, but almost non of them supported Unicode (UTF-8) file. I've found that the only Unicode support IDEs are DreamWeaver 8 and Zend PHP Studio. DreamWeaver provides full support for Unicode. However, DreamWeaver is a web editor rather than a PHP IDE. It only supports basic IntelliSense (or code completion) and doesn't have anything...
3
1596
by: Martin | last post by:
I'm having trouble getting a new PHP/MySQl installation to work. Windows XP Pro, IIS 5.1, PHP 5.1.1, MySQL 5.0.16, ISAPI This is a new computer. The whole setup is for development use only - no access from beyond my own network. PHP seems to be working OK. I can open a test.php page ok - It executes down to the statement where I try to connect to the MySQL database. At that point, nothing further happens. The page is served
13
4008
by: Marvin Zhang | last post by:
Hi, I'm not familiar with web programming, but I have a problem here. I have a page. When a user click one button on it, I will use AJAX to request a PHP script which will do a bunch of tasks, asynchronously. These tasks might take long time so I want to keep the user informed of the progress. The problem is that only the PHP script knows the progress, how can the web page gets these information from PHP script?
2
1984
by: larry | last post by:
I am working on a DB for family data, and in this application the data spans variable amount of rows in multiple tables (one for the adults data, one for "family", one for the kids, another for employment schedule, and another for businesses, etc.). I was thinking on selecting the entire family (IDs of all the related records) and storing them in a session array for easy access (from script to script) as I edit the data, but am wondering...
3
3852
by: DSSMaster | last post by:
I am trying to use windows scheduler to compact a database. In the task run line I have the following: "C:\Program Files\Microsoft Office\OFFICE11 MSACCESS.EXE" _ "C:\Files\Access\Sacroc.mdb" /compact In the task start in box I have the following "C:\Program Files\Microsoft Office\OFFICE11" The database starts to compact and then returns the message
0
1774
by: vozzek | last post by:
Hi all, I've got a mySQL database I've been working with as my localhost for several months now, no connection problems. I'm at the point however, where I need to connect to the database from another site / different IP address. I'm playing around in the PayPal sandbox, and I'm running an instant payment notification php script before the user exits. The included connection file looks like this: <?php $hostname_TFATP =...
7
2025
by: JDOMPer | last post by:
Don’t misunderstand me – I use AJAX, but I think there is a far simpler, elegant alternative that just uses Javascript, the DOM and Php ( hence - JDOMP) for data transfers, and is cross-browser without the need for work arounds. JDOMP works in recent versions of Explorer, Mozilla, Safari and Opera. Please note I will not deal with security issues which are always an issue whenever there is access to a database. You can simply change text on...
0
9721
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10633
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10376
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10114
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9198
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5548
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4331
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3860
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3011
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.