I am running into an issue when I try to write more than 1024 characters to
a memo field. Apparantly the odbc connection I am using does not permit
literals to be larger that 1024 characters. This Memo filed can take
virtually infinate data, so the solution seems to be use parameters. My
problem is I have never heard of this and need this to work ASAP Does
anyone have a simple example of how Parameters work using ASP
I have a problem with input parameter which has Decimal DataType. Stored procedure (SQL 2000) works but it rounds all values off, i.e 5.555 input becomes 6 and 1.3 input becomes 1. In table QTY has data type decimal(5) - precision(8) scale(3). Please, suggest what's wrong with this:
I'm building my asp page using a table. Part of building that table includes: ...... Response.Write("<td>" & rsi.fields(3).value & "</td>") Response.Write("<td><input type=button value=""Remove"" name=RemoveButton onclick=""RemoveAgent();""></td></tr>") ...... ......
My problem is that my table has multiple records each line has a Remove button at the end. I need to pass rsi.fields(0).value to the RemoveAgent routine when the button is pressed. I thought that my onclick event would become........onclick=""RemoveAgent(rsi.fields(0).value) ;....... but I receive a syntax error. Thinking about it it's a bit more complex than that in any case because at the point of clicking the button, I am not sitting on the correct record within the recordset since I am sitting at the eof after creating the table
I want to pass parameters via response.redirect. After a search on google, I have seen various types and i am getting confused on the best way to do it.Can someone let me know if i can do it the same way a href?
Is there code that I can use to 'repeat' code.For example:I have a form that has about 30 fields on it. I then submit it to anotherform that has about 20 fields on it. I then submit the second form to a third and so on. During this process, I pass all of the fileds as Hidden Fields. My code has over 200 hidden fileds in it and sometimes they get mis-spelled or somthing. I thought that I saw something that you can tell the page to 'repeat' certain code for all parameters on the page by using a FOR EACH command.
Is there a way to pass a URL parameter from a previous page to the next page (without clicking a hyperlink)? There are 3 pages. user_edit.asp, user_delete.asp, user_delete2.asp. I want to pass the customer_id parameter from user_edit.asp via a hyperlink to user_delete.asp and then after some asp manipulation I want to pass the existing customer_id parameter to the user_delete2.asp page (or again to user_delete.asp) without the user doing anything (such as accessing a hyperlink).
I have several parameters that I need to pass into a stored procedure. Each parameter holds a comma delimited list.
I tried splitting the parameters and executing the stored procedure doing the following:
Dim CmtIdLoop CmtIdLoop = Split(Request.Form("commentsID"),", ") revwStatLoop = Split(Request.Form("review_status"),", ") abrstatLoop = Split(Request.Form("abr_status"),", ") commentsLoop = Split(Request.Form("comments"),", ") For l = 0 to Ubound(CmtIdLoop) s = CmtIdLoop(l) t = revwStatLoop u = abrstatLoop v = commentsLoop .....
I was just wondering if it's possible to do this type of action, the way i currently have it layed out, the system does not recognise the id variable?
IF NOT Recordset.EOF THEN 'Record Found id=Recordset.Fields("Survey_Id") %> <!--#include file="quiz.asp?id=<%=id%>" --> <% ELSE Response.Write("No survey found.") END IF
I am trying to do any better than this and am losing my confidence daily as I pressumed this to be easy and I am sure once I have done it I will wonder what all the fuss was about!
My experience with ASP is limited to one Degree module and I am trying to build a prototype web site. I need pointing in the right direction to what I presume is a common ASP requirement - a ‘second level of user enquiry’. Code:
i have a folder Services and this folder has index.asp file. i need to put a link in email specific to the user. i can do:
www.myweb.com/Services/index.asp?parm1=1&parm2=2
How i can do this same very thins as
www.myweb.com/Services?parm1=1&parm2=2
as the default file name is index.asp so it will get executed if i put www.myweb.com/Services in the URL Address box. Here when i try to pass parametrs to the folder, this results in page not found.
I need to pass a static parameter to an included ASP file. I'm thinking about using this with a query string, but upon reflection I'm not sure how I can do this. For example:
I wrote a simple client/server chat program and the client runs as an activex control within an asp page. I have the users logging into the page using widows authentication and I'm using Request.ServerVariables("AUTH_USER") to get the users name. I'd like to pass this name to the activex chat client thru the page but I'm having some difficulty. I tried passing it as a parameter to the "Tag" property within the <OBJECT> element like this:
<% username=Request.ServerVariables("AUTH_USER")
username=right(username,len(username)-instr(1,username,"")) ' remove the domain or machine name from the username
When I do this the ActiveX control doesn't appear on the page. Is there a better way to do this? I also tried creating a public sub in the activex control and calling it as a method from within the page but I can't seem to get the syntax right. I keep getting "Object Required" errors.
Have no problem getting my select queries to work using this method:
strSQL = "SELECT tblUI.IPAdd FROM tblUI WHERE (tblUI.IPAdd =?)"
arSPrm = Array(strRemHst)
Set rst = cmd.Execute(,arSPrm)
Can anyone point me to some examples of using this method for UPDATE and INSERT queries? Can't seem to get it to work no matter what I can think of to try. (If it is possible?)
I have a URL that passes on information for a database and looks like this www.domain.com/lead.asp?FirstName=test&LastName=test
I submit this to the domain and page listed above which then uses a 301 redirect to the page below. That page is www.secretdomain.com/nowprocesslead.asp.
My database entry pulls up blank using the the redirect page. Now if I submit the same url to the secret domain, everything passes just fine to the database.
Is there a way to pass the URL info through a redirect? I don't want people to see the second domain, just the first. Code:
On this page, I have a form with a Select box for DistrictName. I would like to pass the selected value to the above query and use it as part of the WHERE clause. I know that is not a problem. I can do the following:
Select * from tblEmployee where DistrictName = '" & Request.Form("DistrictName") & '"
Here is the problem. One of the values in the Select box is "All Districts". How or what do i send to the query to pull employees for all districts?
I am trying to pass a SQL query to the crystal report. The user typically selects some data from a form, and those values will make up the query through a request.form statement. The problem is the report is displaying all records. Code:
My code retrieves a username and a password from a form. Then this information is compared to some usernames and passwords that are stored in a database. The important thing here is that the comparison must be case sensitive meaning that "passWord" is not the same thing as "password"
I have this code, working fine in access 2003
SQL = "SELECT * FROM users WHERE StrComp(username_column,'" & entered_username_in_form & "',0) = 0 AND StrComp(password_column,'" & entered_password_in_form & "',0) = 0"
but get the following error when I run it against my sql 2005 database.
[Microsoft][SQL Native Client][SQL Server]'StrComp' is not a recognized built-in function name.
I don't know the corresponding t-sql for the query.
I have a simple website linking to an access database. The script works fine on my local machine. And it works fine on my regular host. However, I have uploaded the website to a Windows account with GoDaddy and here is my problem.
I am receiving the following error:
Microsoft JET Database Engine error '80040e10' No value given for one or more required parameters. /home.asp, line 10
- the WEIRD thing is that if you hit refresh enough times, the page loads fine. Then, at random (it appears), the error resurfaces. No coding changes at all. Code:
I've been coding since mainframes had 4MB of core memory (yes kiddies, that 4MB), I've never coded a classic ASP page, only ASP.NET. I've noticed many problems in this forum seem to stem from building SQL commands by concatenating strings and could be avoided by using parameter substitution, a totally common concept in ASP.NET. So, is that just something that can't be done in classic ASP?
My problem is: I've created an ASP/MS Access app with Dreamweaver. I have an admin page to edit/delete records. When I edit or delete a record, it works the first time and redirects me back to the main page.
When I click on another record it adds the URL parameter to the end of the previous URL parameter and I get an error. Is there a simple piece of code to check the URL for the same parameter so that it will not just add it to the end.
I am calling an ASP page from JavaScript using window.open(<URL>?<few parameters>) parameters can be in Japanese so I am using encodeURI to encode it. In the ASP files I am using Response.Charset="UTF-8" and still when I check the URL with Request.QueryString it looks OK,however when I call Request("<parameter name>") I get the parameter value not in UTF8 format but in ISO-8859-1, does anyone familiar with this? Is it a known bug with the Request object? Is there a way to force it to deal with the data as UTF-8?
Currently the only solution I have is to taker the value from QueryString and parse the whole URL by myself.
I am using the following code in asp to select some data from an access db. recSel is defined and set further up my webpage, as is rsUpdate User. I cannot work out how to get past this error message
Too few parameters. Expected 1. Can anyone see the problem?
I've had this error before but it was for a different type of command. Does anyone know what this means in relation to the highlighted code or what I might need to do to work on fixing it? Code:
I am trying to send the results of a form to a couple of email addresses, but it is not working. I am required to use a XSL file for this.
I usually don't have problems with sending the results of a form to email addresses because I don't use a XSL file or a complicated function. The XSL file is fine. It is the ASP page that has the problem. Can someone please help me with this? Code:
I have a simple form with a textbox, a combobox and a submit button. I want to also be able to pass the "values" of the textbox and the combobox in the URL. How do I do that? DO I need to set that up in the function? I know this must be simple becuase I can not find any information on how to do it.
I am getting the error "No value given for one or more required parameters" with this basic script.
I have checked the fields are spelt correctly and have capitals in the right place. I have also checked with response.write to see the results it produces and it all looks correct. Code:
I must send to the page below(MailBee.asp) the two parameters UserName and Password. The page MailBee.asp is a different page, the code below is from the page where I have done the form(login.asp), so MailBee.asp is the page where I must do the authentication.That's why I must send to this page the two parameters, but I don't know how can I do this with the method action.Code: