DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Sat, 02 Jun 2007 05:08:24 -0000,    posted on: microsoft.public.dotnet.framework.aspnet.buildingcontrols        back       

Thread Index
  1    Rick
          2    Riki
          3    Rick


Custom Composite Web Control and Validator   
Hello,

I built a composite web control that has a textbox and a date
control.
added my custom control on a webform where there are other standard
controls.
Each control on the form has a required validator.
I need to have a validator for my custom control, but don't know how
to do this.
I added a CustomValidator to the form, but in design mode, my custom
control doesn't appear in the list of controls of the validator.
Any help to work around this will be greatly appreciated.

Thanks,

Rick
Date:Sat, 02 Jun 2007 05:08:24 -0000   Author:  

Re: Custom Composite Web Control and Validator   
Rick wrote:

> Hello,
>
> I built a composite web control that has a textbox and a date
> control.
> added my custom control on a webform where there are other standard
> controls.
> Each control on the form has a required validator.
> I need to have a validator for my custom control, but don't know how
> to do this.
> I added a CustomValidator to the form, but in design mode, my custom
> control doesn't appear in the list of controls of the validator.
> Any help to work around this will be greatly appreciated.


For a CustomValidator, there's no need to indicate a ControlToValidate.
Just leave it blank.
It's your custom validation code that will decide which values it's going to 
check.

-- 

Riki
Date:Mon, 4 Jun 2007 14:31:36 +0200   Author:  

Re: Custom Composite Web Control and Validator   
On Jun 4, 8:31 am, "Riki"  wrote:

> Rick wrote:
> > Hello,
>
> > I built a composite web control that has a textbox and a date
> > control.
> > added my custom control on a webform where there are other standard
> > controls.
> > Each control on the form has a required validator.
> > I need to have a validator for my custom control, but don't know how
> > to do this.
> > I added a CustomValidator to the form, but in design mode, my custom
> > control doesn't appear in the list of controls of the validator.
> > Any help to work around this will be greatly appreciated.
>
> For a CustomValidator, there's no need to indicate a ControlToValidate.
> Just leave it blank.
> It's your custom validation code that will decide which values it's going to
> check.
>
> --
>
> Riki


Hi Riki,

Thanks. I did as you said, and set the args.IsValid accordingly in the
custom validator's event handling sub, but I must be missing something
b/c the event for the custom validator isn't getting fired. I have a
breakpoint in this event and it isn't stopping there. I'm new to aspx
and I'd appreciate any help to make this user control work with the
validator.

Thank you in advance,

Rick
Date:Mon, 11 Jun 2007 07:09:55 -0700   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us