Can anyone add the syntax for a password to this code for me I can't figure
out the syntax. I need to use mappath because I don't know the full path to
the database as it's on a remote server.
<%
set conn=Server.CreateObject("ADODB.Connection")
conn.ConnectionString="Provider=Microsoft.Jet.OLEDB.4.0"
conn.open server.mappath("database.mdb")
conn.close
%>
I am a beginner in ASP and i have the following question: Is it possible to add manually things to the string that the page will send to the other page?
In other words: Do i have to use Form items to add something to the string?
My idea is:
<%Form=Form+"?Hgeheim="werkt"%>
it doesn't work. If it is possible could you please give a example code?
Am collecting numerical entries from text boxes and converting to numbers using:
F1 = Round(CDbl(Request.Form("amout1")),2) F2 = Round(CDbl(Request.Form("amount2")),2) F3 = Round(CDbl(Request.Form("total")),2) F4 = F1 + F2
If F4 <> F3 Then Session("ErrorMessage") = Session("ErrorMessage") & "- Your control amounts do not tie to the Total Deposit amount.<br>" End if
etc.
Sometimes it works, but other times, although the numbers tie out, the calculated amounts are not coming up as equal. I've written the results (F3 & F4) to the screen and they equal, although the server doesn't think so.
Is this an issue with binary number conversion or something. Should I be using something other than CRnd (Delphi has something like C$ or CCurrency)??
I need to create some .asp pages to publish data from our manufacturing lines...but I can't figure out how to establish the connection string and print the data. I've been stuck on this all day and about to start pulling my hair out!!!
As an example, can someone create the most basic code necessary to build a web page that does the following:
a) connect to a SQL version of the Northwind db (assume I have a functioning ODBC connection called 'Northwind_ODBC' on a server called 'ProductionServer')
b) Loop through the records in the [Shippers] table and paste the values in a HTML table (using SELECT * FROM SHIPPERS)
I know it sounds simple but I'm looking through some books and can't find a solution that works on my server.
NOTE: I'm running Server 2003 (with IIS), SQL Server 2000, and I have proven ASP does work on this machine...unfortunately, just not with the code I'm trying to build!!!
I have an ASP page that is connected to a DBF file and it works right on my local server ( XP professional) but when i publish it in my internet server, i get this error: --------------------
Microsoft OLE DB Provider for ODBC Drivers error '80040e37'
[Microsoft][ODBC Visual FoxPro Driver]File 'person.dbf' does not exist.
I've been using Dreamweaver MX connecting to an IIS 6 server on win2003. I've used an MS Access DB (2000 format) If I use server DNS, I connect to my via ASP with out a problem. However, my ISP does not support DNS connections, so I've been trying for a few days to get a dns less connection work. This is the closes I've got:
I can setup the connection and can test the Record set, it's OK Can see the table data in the test in DW. But when I launch the page, I get a http 500 error. And again, I had no problem with DNS in the same environment.
I am using the following code to connect to web.com (mysql). I am having problems connecting. Has anyone use web.com before if so, can I get an example of how to write my connection string? Code:
My asp application works well when i set up a default user for the asp application. i wish to integrate user with SQL server by using "Trusted_Connection=Yes"
it works well within the domain workstations (within LAN)
however some workstations (workgroup) are out of the domain, such as remote workstations by VPN. i try to add domain login details at those remote workstations but still fails.
I really like this forum as I can usually find the answer to all my questions by searching, but I haven't been able to find a way to resolve this problem. This is my setup. We have 2 local servers. One running WinNT that handles all our internal databases in dbf formats. The other server is WinServer 2k3 and it handles all webstuff. The Win2k3 Server logs onto the WinNT Server and can see and open all the files. If I copy a file from the NT Server to the 2k3 server, I can utilize the database using the connect string:
but, I cannot connect to it directly on the other server. I believe it is a permissions issue, but if I change the Annonomus Access user to one that can access the other server, it asks for a password. I have even tried a virtual server but cannot find a connection string that will allow me to access it.
I need help in creating a DSNless connection string for the database driven website I am doing using ASP and Access. However I get persistent error message even though I use "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=c:inetpubwwwrootdatabasesabc.mdb"
Since I use IIS to test the ASP pages, do I need to amend the connection string? Is it necessary to amend the conection string to allow the driver to run on local machine or testing server? I am confused.
I usually create a db.asp file, and include it on each page i need the db connection, but where do you think is the best place to store the db connection? anything a bit more secure?
Ive created an ASP CMS system which works fine locally. Now its time to upload it to my webserver and make it live. Now locally I have been using a DSN to connect to the MySQL database..now i need to use a connection string. How will i do this. At present my DSN connection code is as follows: Code:
I am using DW8 to create a simple database-driven site using IIS and ASP vbscript. I have created a virtual directory in IIS and I have created the DSN, connection and appropriate recordsets. The problem is I keep getting the following error:
The line the error refers to is always the connection string. And it seems to be intermittent. Sometimes the page works fine, other times I get this error - but I can't figure out why. I always make sure that I save my files and put them to the server so I really can't work this out.
Microsoft OLE DB Provider for ODBC Drivers error '80004005' [Microsoft][ODBC Microsoft Access Driver]General error Unable to open registry key 'Temporary (volatile) Jet DSN for process 0x57c4 Thread 0x3474 DBC 0x1234284 Jet'.
i am using access database with asp . there is no password assigned to mdb file. but now i want to assign a password protection to my database so that nobody could open it despite downloading it. i am using following connection string
DB = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & _ Server.MapPath("kb.mdb")
now i want to know what shall be connection string when i shall assign password to my access database file.
In a asp project I am required to come up with a solution where the administrator of the sytem should be able to set the desired connection string by checking one of two options (access or sql server).
The connection.asp is a asp page that holds the connection strings. I am trying to get the value of chosen option to write a if statement in the connection string. ie. if. then connstring else connstring
how does one store the value of the chosen opton to use it in the connection.asp without using a session variable.
I currently have my SQL Server connection string in an Application variable in the global.asa. Could that be a security risk? I have heard that with Cold Fusion, when there is a page error. the actual Connection String is written to the screen as part of the error page.
I'm quite sure that would not occur in ASP but just wanted to be sure, and get a few expert opinions.
I ALWAYS forget this cause we ALWAYS turn our db connections into COM components. That said... I need one for this project . Here's my base Access one:
DBPath ="C:datastoresmediacd.mdb" Set Con = Server.CreateObject( "ADODB.Connection" ) Con.Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & DBPath
I just don't quite remember the SQL Server variation.
if this is possible. or something close to this being possible
objConn = Server.CreateObject("ADODB.Connection") objConn.Open ("my data base information") objRS = Server.CreateObject("ADODB.Recordset") type = "Select * from document.oppsform.select_states.value" <----- Here is where the javascript comes into play objRS.Open (type, objConn)
I was looking at another post, and what the person did was:
Dim strConn strConn = "string" application("strConn") = strConn Now, am I able to create a connection object in my global.asa like so, and then keep my existing syntax for all my hundreds of queries?
Dim strCon strCon = string Set Connect = Server.CreateObject("ADODB.Connection") Connect.Open strCon ?
I'm trying to SAVE bandwidth, so I want to create my connection in global.asa instead of each time my include file 'top.asp' is executed. I can also close it easily...
PS. I believe Application_OnStart() is the best place to put it, am I correct?
I have a OLEDB Connection String that is working very well for me. My question is that I read that you can store the Connection String in a seperate include file or somewhere else. I am just wondering where is the proper place to store this Connection String and how do I call it from my application. Code:
stringB = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath("DB.MDB") & ";Connect Timeout=30"
I have use the above connection string in an ASP application, stringA with SQL Server, it works! stringB with MS ACCESS, it doesnt works if I add the "connect timeout" parameter! How can I solve it!? so that I can set the connection timeout when I using MSACCESS as Database.
I have BIG Problem in ASP.I have a ADO Connection that I Want to Connect to DBASE IV Database Located in a Local Networked System. The DBASE Database is located in other system then the IIS System in the same Network.But Both are in the same Local Network
When I Try the Connection String: ConStr = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source =
addbdbase;Extended Properties = DBASE IV; User ID=Admin;Password="
I get ERROR "is not a valid path. Make sure that the path name is spelled correctly and that you are connected to the server on which the file resides."But When I Try the DB in same system that works fine. I am Confused If the way I used to connecto to Networked SYstem is Correct?
got this code , among others (attached below) for shopping cart from a friend and it suppose to work, however it requires a connection string to make this database driven website works, so my question is how do I insert a connection string code in the string so that it will make a connection to the Access database. Code: