Click here to Skip to main content
15,891,372 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: [ASP.NET C#] Postback and updatepanel issues. Pin
Member 791246114-Jun-14 4:21
Member 791246114-Jun-14 4:21 
GeneralRe: [ASP.NET C#] Postback and updatepanel issues. Pin
jkirkerx14-Jun-14 8:33
professionaljkirkerx14-Jun-14 8:33 
QuestionSession for Listbox Pin
Dalina Cheriyan6-Jun-14 3:11
Dalina Cheriyan6-Jun-14 3:11 
AnswerRe: Session for Listbox Pin
ZurdoDev6-Jun-14 10:29
professionalZurdoDev6-Jun-14 10:29 
GeneralHow to increase .net application performance Pin
venumadhav.narla7776-Jun-14 0:39
venumadhav.narla7776-Jun-14 0:39 
GeneralRe: How to increase .net application performance Pin
Richard Deeming6-Jun-14 1:01
mveRichard Deeming6-Jun-14 1:01 
AnswerRe: How to increase .net application performance Pin
thatraja6-Jun-14 9:58
professionalthatraja6-Jun-14 9:58 
Question'Submit' button related errors Pin
Member 87616675-Jun-14 14:26
Member 87616675-Jun-14 14:26 
Hello

In my 'register new user' ASP.NET Web form, I am experiencing two errors which I have not been able to resolve. I have a register.aspx file and a register.aspx.vb file.

I get this error in my aspx file:

BC30456: 'SubmitButton_Click' is not a member of 'ASP.account_register_aspx'.

This relates to this line:

 </div>

      <asp:Button ID="SubmitButton" runat="server" OnClick="SubmitButton_Click" Text="Register" CssClass="btn btn-default" Height="32px" />
   
    <br />
   
</asp:Content>


and in my aspx.vb file and, presumably related to the above error in my aspx file, where I have:

Protected Sub SubmitButton_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles SubmitButton_Click.Click.


I get the following error:

VB
Handles clause requires a WithEvents variable defined in the containing type or one of its base types.


I have attempted to read up on Handles/WithEvents tonight, but it's a bit above me at the moment.

In context, the Handles error occurs in this snippet:

Partial Class _Register
    Inherits System.Web.UI.Page

    Protected Sub SubmitButton_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles SubmitButton_Click.Click. 
        Using(conn As OleDbConnection = New OleDbConnection(System.Configuration.ConfigurationManager.ConnectionStrings("usersConnectionString").ConnectionString))
        .Dim sql = "INSERT INTO userlist (username,password, strEmail) VALUES (@username,@password, @strEmail)"
        .Using cmd = New OleDbCommand(sql, conn)
        conn.Open()
        cmd.Parameters.AddWithValue("@username", txtusername.Text)
        cmd.Parameters.AddWithValue("@password", txtpassword.Text)
        cmd.Parameters.AddWithValue("@strEmail", txtstrEmail.Text)
        cmd.ExecuteNonQuery()
                End Using
            End Using
    End Sub
End Class


Any help would be appreciated.
AnswerRe: 'Submit' button related errors Pin
Richard Deeming6-Jun-14 0:59
mveRichard Deeming6-Jun-14 0:59 
GeneralRe: 'Submit' button related errors Pin
Member 87616676-Jun-14 6:02
Member 87616676-Jun-14 6:02 
GeneralRe: 'Submit' button related errors Pin
Richard Deeming6-Jun-14 7:33
mveRichard Deeming6-Jun-14 7:33 
GeneralRe: 'Submit' button related errors Pin
Member 87616676-Jun-14 7:43
Member 87616676-Jun-14 7:43 
QuestionBeginner: using update_demo.asp - Datatype Mismatch Error Pin
Istteffanny Isloure Araujo4-Jun-14 22:49
Istteffanny Isloure Araujo4-Jun-14 22:49 
AnswerRe: Beginner: using update_demo.asp - Datatype Mismatch Error Pin
thatraja4-Jun-14 23:52
professionalthatraja4-Jun-14 23:52 
QuestionUnable to close a modal pop up after opening an pdf document Pin
aditya kiran maroju4-Jun-14 18:36
aditya kiran maroju4-Jun-14 18:36 
QuestionRe: Unable to close a modal pop up after opening an pdf document Pin
Vasudevan Deepak Kumar13-Jun-14 2:35
Vasudevan Deepak Kumar13-Jun-14 2:35 
Questionhighlight main menu item of current page. Also highlight when sub menu item is selected through javascript in ASP.net Pin
hilbiazhar4-Jun-14 2:41
hilbiazhar4-Jun-14 2:41 
Questionkinect with web Pin
vinayak.ghanti3-Jun-14 20:42
professionalvinayak.ghanti3-Jun-14 20:42 
AnswerRe: kinect with web Pin
Richard MacCutchan3-Jun-14 22:04
mveRichard MacCutchan3-Jun-14 22:04 
QuestionRepeater Control with show and hide boxes Pin
indian1433-Jun-14 10:41
indian1433-Jun-14 10:41 
AnswerRe: Repeater Control with show and hide boxes Pin
DamithSL3-Jun-14 16:47
professionalDamithSL3-Jun-14 16:47 
GeneralRe: Repeater Control with show and hide boxes Pin
indian1435-Jun-14 7:14
indian1435-Jun-14 7:14 
QuestionBeginner to Visual Studio Pin
Member 87616672-Jun-14 13:31
Member 87616672-Jun-14 13:31 
AnswerRe: Beginner to Visual Studio Pin
Richard Deeming3-Jun-14 1:20
mveRichard Deeming3-Jun-14 1:20 
GeneralRe: Beginner to Visual Studio Pin
Member 87616673-Jun-14 2:14
Member 87616673-Jun-14 2:14 

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.