Prompt a MsgBox on Delete Button Click event


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 4 of 4

Thread: Prompt a MsgBox on Delete Button Click event

  1. #1
    Steve Guest

    Prompt a MsgBox on Delete Button Click event


    Hi All,
    I have a Delete button on my web form. When user clicks the Delete button,
    I want to prompt a confirmation message box with Yes and No button. How can
    I do it in my DeleteButton_Click event? How can I get the value return by
    the MsgBox or how can I know which button the user clicked?

    Dim sMsg As String
    sMsg = "Do you want to delete all records?"
    response.write("<"+"Script language=""VBScript"">"+chr(13))
    response.write("Msgbox """+ sMsg +" "",4, "" Delete Confirmation"" "+chr(13))

    response.write("</"+"Script>")

    If vbYes Then
    'Delete Record here...
    End If

    Thanks in advance,
    Steve


  2. #2
    John Butler Guest

    Re: Prompt a MsgBox on Delete Button Click event


    "Steve" <vb.@127.0.0.1> wrote in message
    news:3ddf01cc$1@tnews.web.devx.com...
    >


    try this control, works nicely:
    http://www.asp.net/ControlGallery/Co...123&tabindex=2





    rgds
    John Butler



  3. #3
    Steve Guest

    Re: Prompt a MsgBox on Delete Button Click event


    Thanks. Is the control free to use? There is no licensing information available.

    "John Butler" <nospamjrbutler@btinternet.com> wrote:
    >
    >"Steve" <vb.@127.0.0.1> wrote in message
    >news:3ddf01cc$1@tnews.web.devx.com...
    >>

    >
    >try this control, works nicely:
    >http://www.asp.net/ControlGallery/Co...123&tabindex=2
    >
    >
    >
    >
    >
    >rgds
    >John Butler
    >
    >



  4. #4
    John Butler Guest

    Re: Prompt a MsgBox on Delete Button Click event


    "Steve" <vb.@127.0.0.1> wrote in message
    news:3de301b6$1@tnews.web.devx.com...
    >
    > Thanks. Is the control free to use? There is no licensing information

    available.

    Andy's work is freely downloadable, but he invites you to use PayPal and
    make a donation if you find his code useful.

    see: http://www.metabuilders.com/default.aspx

    rgds
    John Butler



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center