Solved

ASP - removeKey()

Posted on 1998-08-13
6
153 Views
Last Modified: 2013-12-25
What is the syntax of the removeKey() method ?

I want to delete several variables contained in the URL and I tried like below, but it doesn't work !!!

removeKey(Request.ServerVariables("QUERY_STRING"), "COM_LIGNE", "COM_QUANT").
0
Comment
Question by:netf_ds
  • 3
  • 3
6 Comments
 
LVL 28

Expert Comment

by:sybe
ID: 1858988
ServerVariables are read-only

Maybe this will work:

MyVar = Request.ServerVariables("QUERY_STRING")

removeKey(MyVar, "COM_LIGNE", "COM_QUANT")

But I could not find the removeKey function, so I am not sure
0
 

Author Comment

by:netf_ds
ID: 1858989
Sorry, but it doesn't change anything !

Microsoft VBScript runtime error '800a01c2'

Wrong number of arguments or invalid property assignment: 'removeKey'

0
 
LVL 28

Expert Comment

by:sybe
ID: 1858990
I think you must have removeKey() defined somewhere in your code. Maybe in some include, or in the global.asa

Look there for how the sub or function is defined.

Your error message suggests that you should not pass 3 parameters to the function. Try passing 2 or 4 parameters.


this is what I get when I use your code:

=======================
Microsoft VBScript compilation error '800a0414'

Cannot use parens when calling a Sub

/asp/test/removekey.asp, line 5

removeKey(Request.ServerVariables("QUERY_STRING"), "COM_LIGNE", "COM_QUANT")
===============================


0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 

Author Comment

by:netf_ds
ID: 1858991
Oooops,

You're right sybe : removeKey was a function I didn't saw in my application and not a predifined function (that's why we both didn't find any reference !). In fact it's not really my application, someone else began it and I was asked to finish it.

OK, if you want to earn the 50 points, I think you have to return me a blank answer.
0
 
LVL 28

Accepted Solution

by:
sybe earned 50 total points
ID: 1858992
ok
0
 

Author Comment

by:netf_ds
ID: 1858993
I finaly wrote :

removeKey(removeKey(Request.ServerVariables("QUERY_STRING"), "COM_QUANT"), "COM_LIGNE")
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Both Easy and Powerful How easy is PHP? http://lmgtfy.com?q=how+easy+is+php (http://lmgtfy.com?q=how+easy+is+php)  Very easy.  It has been described as "a programming language even my grandmother can use." How powerful is PHP?  http://en.wikiped…
Author Note: Since this E-E article was originally written, years ago, formal testing has come into common use in the world of PHP.  PHPUnit (http://en.wikipedia.org/wiki/PHPUnit) and similar technologies have enjoyed wide adoption, making it possib…
This tutorial walks through the best practices in adding a local business to Google Maps including how to properly search for duplicates, marker placement, and inputing business details. Login to your Google Account, then search for "Google Mapmaker…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now