Click here to Skip to main content
15,895,256 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: Small Query help needed Pin
Dinesh Mani10-Dec-09 19:26
Dinesh Mani10-Dec-09 19:26 
AnswerRe: Small Query help needed Pin
Blue_Boy10-Dec-09 20:54
Blue_Boy10-Dec-09 20:54 
Questionis it possible? Pin
Hema Bairavan10-Dec-09 18:51
Hema Bairavan10-Dec-09 18:51 
AnswerRe: is it possible? Pin
Anurag Gandhi10-Dec-09 19:24
professionalAnurag Gandhi10-Dec-09 19:24 
AnswerRe: is it possible? Pin
Dinesh Mani10-Dec-09 19:38
Dinesh Mani10-Dec-09 19:38 
AnswerRe: is it possible? Pin
farogh haider14-Dec-09 19:20
farogh haider14-Dec-09 19:20 
QuestionCustom Validator for DataGrid Template Column Pin
Graham Baxter10-Dec-09 14:15
Graham Baxter10-Dec-09 14:15 
AnswerRe: Custom Validator for DataGrid Template Column Pin
sashidhar10-Dec-09 18:57
sashidhar10-Dec-09 18:57 
For using Custom Validator and Regex
Graham Baxter wrote:
args.IsValid = false

It Wont Stop the execution it will go the the Next event..!
But You can check the Event in the Button click I also got this problem .
I overcome it by Checking the args value in button click..!

But For You Case You have to go for client side validation..!
Here is the sample code i used for Custom Validation
protected void CustomValidator1_ServerValidate(object source, ServerValidateEventArgs args)
{
    try
    {
        int timetmp = Convert.ToInt32(EmailSettings.ReserErrorTime);
        int time1 = timetmp + 15;
        DateTime current = System.DateTime.Now.AddMinutes(time1).ToUniversalTime ();

        if (txtReservationdate.Text != "")
        {
            string Date11 = ReserExactTime.Value;
            string date12 = Date11.Substring(4, 21);
            DateTime resertime = Convert.ToDateTime(date12);

            if (resertime > current)
            {
                temp = true;
            }
            else
            {
                temp = false;

            }
        }
        else
        {

            string Date11 = ReserExactTime.Value;
            string date12 = Date11.Substring(4, 21);
            DateTime resertime = Convert.ToDateTime(date12);
            if (resertime > current)
            {
                temp = true;
            }
            else
            {
                temp = false;

            }
        }

    }
    catch (Exception ie)
    {
        logger.Error("ReserDate :-" + ie.Message, ie);
    }
}


and i check it button click of the temp value..!




try this link for regex..!
http://msdn.microsoft.com/en-us/library/ms998267.aspx[^]


LatestArticle :Log4Net

Why Do Some People Forget To Mark as Answer .If It Helps.

GeneralRe: Custom Validator for DataGrid Template Column Pin
Graham Baxter11-Dec-09 1:52
Graham Baxter11-Dec-09 1:52 
AnswerRe: Custom Validator for DataGrid Template Column Pin
Dinesh Mani10-Dec-09 18:58
Dinesh Mani10-Dec-09 18:58 
GeneralRe: Custom Validator for DataGrid Template Column Pin
Graham Baxter11-Dec-09 1:41
Graham Baxter11-Dec-09 1:41 
AnswerRe: Custom Validator for DataGrid Template Column Pin
Dinesh Mani11-Dec-09 2:13
Dinesh Mani11-Dec-09 2:13 
GeneralRe: Custom Validator for DataGrid Template Column Pin
Graham Baxter11-Dec-09 2:20
Graham Baxter11-Dec-09 2:20 
QuestionInsert image with html editor Pin
Richard Blythe10-Dec-09 8:50
Richard Blythe10-Dec-09 8:50 
AnswerRe: Insert image with html editor Pin
Abhishek Sur10-Dec-09 11:21
professionalAbhishek Sur10-Dec-09 11:21 
GeneralRe: Insert image with html editor Pin
farogh haider14-Dec-09 19:24
farogh haider14-Dec-09 19:24 
Questionupdate global.asax variable from javascript Pin
Munteanu Ciprian10-Dec-09 8:12
Munteanu Ciprian10-Dec-09 8:12 
AnswerRe: update global.asax variable from javascript Pin
Petr Pechovic10-Dec-09 10:36
professionalPetr Pechovic10-Dec-09 10:36 
GeneralRe: update global.asax variable from javascript Pin
Munteanu Ciprian10-Dec-09 18:17
Munteanu Ciprian10-Dec-09 18:17 
GeneralRe: update global.asax variable from javascript Pin
Petr Pechovic10-Dec-09 19:58
professionalPetr Pechovic10-Dec-09 19:58 
GeneralRe: update global.asax variable from javascript Pin
Munteanu Ciprian11-Dec-09 1:46
Munteanu Ciprian11-Dec-09 1:46 
GeneralRe: update global.asax variable from javascript Pin
Petr Pechovic11-Dec-09 2:48
professionalPetr Pechovic11-Dec-09 2:48 
GeneralRe: update global.asax variable from javascript Pin
Munteanu Ciprian11-Dec-09 2:53
Munteanu Ciprian11-Dec-09 2:53 
GeneralRe: update global.asax variable from javascript Pin
Munteanu Ciprian11-Dec-09 3:15
Munteanu Ciprian11-Dec-09 3:15 
QuestionHow to update records of a table automatically based on date Pin
Krishhhhhhhhhhhhhh10-Dec-09 7:11
Krishhhhhhhhhhhhhh10-Dec-09 7:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.