ciao,
sto iniziando a fare delle cose molto semplici, però non capisco dove sbaglio perciò non prendetemi a calci. Allora sto facendo una semplice prova di login e la faccio cosi:
il codice HTML è questo:codice:Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click If User.Text = "prova" And Pwd.Text = "prova" Then Errore.Visible = True Errore.Text = "User o Password GIUSTE" Else Errore.Visible = True Errore.Text = "User o Password ERRATE" End If End Sub
Dov'è che sbaglio?codice:<%@ Page Language="vb" AutoEventWireup="false" Codebehind="login.aspx.vb" Inherits="Prova_NET.WebForm1"%> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML> <HEAD> <title>WebForm1</title> <meta name="GENERATOR" content="Microsoft Visual Studio.NET 7.0"> <meta name="CODE_LANGUAGE" content="Visual Basic 7.0"> <meta name="vs_defaultClientScript" content="JavaScript"> <meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5"> </HEAD> <body MS_POSITIONING="GridLayout"> <form id="Form1" method="post" runat="server"> <asp:Label id="Label1" style="Z-INDEX: 101; LEFT: 8px; POSITION: absolute; TOP: 8px" runat="server">User Name :</asp:Label> <asp:Label id="Errore" style="Z-INDEX: 106; LEFT: 19px; POSITION: absolute; TOP: 137px" runat="server" Width="275px" Visible="False"></asp:Label> <asp:Button id="Button1" style="Z-INDEX: 105; LEFT: 15px; POSITION: absolute; TOP: 78px" runat="server" Text="Submit" OnClick="Button1_Click"></asp:Button> <asp:TextBox id="Pwd" style="Z-INDEX: 104; LEFT: 96px; POSITION: absolute; TOP: 37px" runat="server" TextMode="Password" Width="153px"></asp:TextBox> <asp:Label id="Label2" style="Z-INDEX: 103; LEFT: 15px; POSITION: absolute; TOP: 42px" runat="server">Password :</asp:Label> <asp:TextBox id="User" style="Z-INDEX: 102; LEFT: 95px; POSITION: absolute; TOP: 8px" runat="server"></asp:TextBox> </form> </body> </HTML>
se vi può essere utile sto utilizzando la suite Vs.NET.

Rispondi quotando
