...

View Full Version : Exclude specific form types when using Request.Form.Count



donmateo
11-15-2007, 08:16 PM
Is it possible when counting form elements using Request.Form.Count to exclude certain types? (i.e. hidden, submit)

If not, does anyone have any suggestions on how I could achieve this using a different method?

Thanks,

Matt

shyam
11-15-2007, 09:54 PM
unfortunately the HTTP protocol does not allow the identification of the type of the input that resulted in a particular posted value

Whatever Jr.
11-16-2007, 08:41 AM
The only way to do this is exclude cetain input types based on their names.
Use prefixes for different input types. Loop through all the form elements and count the input types you want in the list.

HTH, Tom

shakir
11-19-2007, 12:32 PM
if submit a form by get or post all the object in the form will be loaded
so only way to exclude is to make loop in all object and applay filter like below

For i= 1 To Request.Form("FormName").Count
if Request.Form("Formname")(item)<>"FldName" then count =count+1
Next



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum