Re: Overloading security check on dropdown, is it possible??



Create a Custom Control that inherits DropDownList and leave off the
[SupportsEventValidation]
attribute from the class.

Use that control rather than DropDownList and you will effectively disable
event validation for a single control on your page. Everything else will
function as normal.
--
Regards
Stephen Davies


"Søren M. Olesen" wrote:


Yeah, I know I can disable the EnableEventValidation, but the I'd have to
check everything myself, I'd prefer to only check the stuff I know could be
changed from JScript....

Regards,

Søren



"Dominick Baier [DevelopMentor]" <dbaier@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
wrote in message news:4580be631a29db8c86f324258b970@xxxxxxxxxxxxxxxxxxxxx
Hi,
i guess you are getting an ArgumentException?

you can disable that check by setting EnableEventValidation=false on the
page - but then - you have to thoroughly verify every single postback.

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

Hi

I'm trying to populate a dropdown list on a page, with the result from
an
AJAX request, however, because my dropdown is runat="server" I get a
security error when posting back my page.
I guess that makes sence since a hacker could attemt to compromise the
webserver this way, however in my situation it's a bit of a
problem.....
Is there a way to make the security check my self, so that I can
determine whether the data is OK or not??

TIA

Søren






.



Relevant Pages

  • Re: Create control with drop-down similar to ComboBox
    ... problem (more or less I am changing the control size on dropdown, ... a parent large enough to hold the entire dropdown). ... Find great Windows Forms articles in Windows Forms Tips and Tricks ... private void button1_Click ...
    (microsoft.public.dotnet.framework.windowsforms)
  • Re: Data List Insert new problem
    ... Microsoft MSDN Online Support Lead ... I try this solution but it dosen't seems to work so I changed the dropdown ... So for the control display the color lists you selected from database, ... Now when I'm selecting let say GN_ID 35 in the the drop down ...
    (microsoft.public.dotnet.framework.aspnet)
  • ViewsState, DropDownList and WebControl
    ... This class Load an ASCX control (that contains other controls in itself like ... DataBindand if it's not postback, ... Tengo una clase que hereda de WebControl ... pero el dropdown me sale completamente vacio. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: DropDownList problem
    ... I am trying to develop a composite control. ... When I pick a value in a a DropDown I want to apply some RowFilter to my ... private DropDownList drAttrAdditional = new DropDownList; ... protected override void CreateChildControls() ...
    (microsoft.public.dotnet.framework.aspnet.webcontrols)
  • Re: explanation of when need to repopulate control
    ... composite controls from my composite control so that there is only drop down ... dropdown list's SelectedIndexChanged event, which then re-populates the ... private void fasFiscalAgent_FiscalAgentChanged ...
    (microsoft.public.dotnet.framework.aspnet.buildingcontrols)