[ nristic @ 12.08.2003. 17:56 ] @
Imam dva pitanja 1.U Code-Behind stranici definiram custom validator pomoću donje procedure. Public Sub ValidateThis(Sender As Object,E As ServerValidateEventArgs) If Len(e.Value) < "8" then e.IsValid=false ElseIf Len(e.Value) > "40" then e.IsValid=false End If If InStr(e.Value,"@")=0 then and Instr(e.Value,".") < 2 then e.IsValid=false Else e.IsValid=true End If End Sub Problem je u tome što mi izbaci grešku tipa name Len is not declared 2.Kako pomoću kontrole rangeValidator napraviti da mi ulazni string recim ime bude najmanje 3 znaka a najviše 15 znakova ? Probao sam ovo ali mi izbaci grešku. <asp:rangevalidator id="rv1" runat="server" controltovalidate="control" minimumvalue="3" maximumvalue="15" type="tring" errormessage="Greška"/> |