logo

Visual Basic dotnet - buttons on a web page

Morto posted on Tuesday, February 12, 2008 4:08 PM

I added two buttons to a web page.  One has 'Causes Validation' set to True -
the othe to false.

When I click the button set to 'Causes Validation' - the expected validation
messages appear.

When I click the button with no validation - nothing happens.
What I expected was that the "Response.Redirect" line would be fired.

Private Sub btnCancel_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnCancel.Click
Response.Redirect("Default.aspx")
End Sub

If I set a stop point at the subroutine - it is ignored.

Any suggestions as to what I am missing?
reply


Did you double check that CausesPostback is set to True?

dotNetDav posted on Friday, March 14, 2008 3:44 PM

Did you double check that CausesPostback is set to True?

David

======================================
David McCarter [Microsoft MVP]
www.dotNetTips.com
David McCarter''''s .NET Coding Standards available at:
http://www.cafepress.com/geekmusicart.1654787045
reply


Didn't Find The Answer You Were Looking For?

View .NET Posts   Ask A New Question

EggHeadCafe has experts online right now that may know the answer to your question.  We pay them a bonus for answering as many questions as they can.  So, why not help them and yourself by becoming a member (free) and ask them your question right now?
Create Account & Ask Question In Live Forum

Previous .NET conversation.

.NET Distributed Applications    .NET Framework    ADO.NET    ASP.NET    ASP.NET Security    ASP.NET Web Controls    ASP.NET Web Services    .NET CLR    .NET Compact Framework    .NET Drawing GDI+    .NET COM Interop    .NET Performance    .NET Web Services    .NET Windows Forms    .NET WinForms Controls    .NET    C#    VB.NET    VC++.NET    .NET Security    Xml    Visual Studio .NET Debugging    Xml    Xsl    JScript    VBScript    WSH    Smart Phone Developer    VB COM    VB Controls    VB Crystal    VB DataBase ADO    VB Syntax    VB WinAPI    VC ATL    VC Debugger    VC Language    VC MFC    VC STL    Visio Developer VBA    WindowsCE Embedded VC    Powershell    .NET Microframework    VB Vista Compatibility    Deployment Server    .NET Microframework Porting   




  $1000    Adam Houldsworth - $188  |  Jonathan VH - $141  |  Kirtan Patel - $119  |  F Cali - $112  |  Huggy Bear - $87  |  more Neado  |  Free Icons  |  Privacy  |   (c) 2010