Javascript in ASP.NET

Discussion in 'ASP .Net' started by Peter Afonin, Jun 22, 2006.

  1. Peter Afonin

    Peter Afonin Guest

    hello,

    I've been using Javascript in ASP.Net before, but I cannot figure out how to
    solve this particular puzzle. I was mostly registering JS at startup, but
    this is not a case.

    The task is very trivial: The Sub is running, when certain condition is met,
    the user gets a message box with OK and Cancel buttons, asking him, whether
    he wants to continue. If he clicks OK, the routine keeps running, if
    Cancel - the Sub exits. That's it, a very common task in Windows
    applications. Is it possible to do the same in ASP.NET?

    I would appreciate any suggestions.

    Thank you,

    --
    Peter Afonin
    Peter Afonin, Jun 22, 2006
    #1
    1. Advertising

  2. Peter,

    You need to call javascript method window.confirm(...);

    Eliyahu

    "Peter Afonin" <> wrote in message
    news:...
    > hello,
    >
    > I've been using Javascript in ASP.Net before, but I cannot figure out how
    > to solve this particular puzzle. I was mostly registering JS at startup,
    > but this is not a case.
    >
    > The task is very trivial: The Sub is running, when certain condition is
    > met, the user gets a message box with OK and Cancel buttons, asking him,
    > whether he wants to continue. If he clicks OK, the routine keeps running,
    > if Cancel - the Sub exits. That's it, a very common task in Windows
    > applications. Is it possible to do the same in ASP.NET?
    >
    > I would appreciate any suggestions.
    >
    > Thank you,
    >
    > --
    > Peter Afonin
    >
    >
    Eliyahu Goldin, Jun 22, 2006
    #2
    1. Advertising

  3. > The task is very trivial: The Sub is running, when certain condition is met,
    > the user gets a message box with OK and Cancel buttons, asking him, whether
    > he wants to continue. If he clicks OK, the routine keeps running, if
    > Cancel - the Sub exits. That's it, a very common task in Windows
    > applications. Is it possible to do the same in ASP.NET?


    If you mean the sub is a server side process and you want to pop up a
    JavaScript dialog to the web user part way through, then no. You'll have to
    perform part of the processing, request information from the user, then start
    a new sub with the previous data and any new information the user supplies.
    =?Utf-8?B?TGVvbiBNYXluZQ==?=, Jun 22, 2006
    #3
  4. The JavaScript "Confirm" method should do the trick.

    Here are the details, along with some free components that will do it for
    you:
    http://SteveOrr.net/articles/ClientSideSuite.aspx

    --
    I hope this helps,
    Steve C. Orr, MCSD, MVP
    http://SteveOrr.net


    "Peter Afonin" <> wrote in message
    news:...
    > hello,
    >
    > I've been using Javascript in ASP.Net before, but I cannot figure out how
    > to solve this particular puzzle. I was mostly registering JS at startup,
    > but this is not a case.
    >
    > The task is very trivial: The Sub is running, when certain condition is
    > met, the user gets a message box with OK and Cancel buttons, asking him,
    > whether he wants to continue. If he clicks OK, the routine keeps running,
    > if Cancel - the Sub exits. That's it, a very common task in Windows
    > applications. Is it possible to do the same in ASP.NET?
    >
    > I would appreciate any suggestions.
    >
    > Thank you,
    >
    > --
    > Peter Afonin
    >
    >
    Steve C. Orr [MVP, MCSD], Jun 22, 2006
    #4
  5. Peter Afonin

    Peter Afonin Guest

    Thank you all for your help!

    Peter

    Steve C. Orr [MVP, MCSD] wrote:
    > The JavaScript "Confirm" method should do the trick.
    >
    > Here are the details, along with some free components that will do it for
    > you:
    > http://SteveOrr.net/articles/ClientSideSuite.aspx
    >
    > --
    > I hope this helps,
    > Steve C. Orr, MCSD, MVP
    > http://SteveOrr.net
    >
    >
    > "Peter Afonin" <> wrote in message
    > news:...
    > > hello,
    > >
    > > I've been using Javascript in ASP.Net before, but I cannot figure out how
    > > to solve this particular puzzle. I was mostly registering JS at startup,
    > > but this is not a case.
    > >
    > > The task is very trivial: The Sub is running, when certain condition is
    > > met, the user gets a message box with OK and Cancel buttons, asking him,
    > > whether he wants to continue. If he clicks OK, the routine keeps running,
    > > if Cancel - the Sub exits. That's it, a very common task in Windows
    > > applications. Is it possible to do the same in ASP.NET?
    > >
    > > I would appreciate any suggestions.
    > >
    > > Thank you,
    > >
    > > --
    > > Peter Afonin
    > >
    > >
    Peter Afonin, Jun 22, 2006
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Poppy
    Replies:
    1
    Views:
    7,551
    Mike Casey
    Dec 18, 2003
  2. David Virgil Hobbs
    Replies:
    0
    Views:
    504
    David Virgil Hobbs
    Jan 6, 2004
  3. Ben
    Replies:
    3
    Views:
    1,114
  4. Andrea Raimondi
    Replies:
    1
    Views:
    434
  5. Amelyan
    Replies:
    2
    Views:
    132
    Amelyan
    Apr 25, 2005
Loading...

Share This Page