Forum: ASP.NET |
Thema:
Re: ASPX Seite wird nicht richtig angezeigt.... |
Von:
G. Guest (
12.04.2006 16:25) |
Hier der Quellcode auch vom Disigner:
Imports System.Web.Security
Public Class WebFrmLogin
Inherits System.Web.UI.Page
Private blnMylogin As Boolean = False
#Region " Vom Web Form Designer generierter Code "
'Dieser Aufruf ist für den Web Form-Designer erforderlich.
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
End Sub
Protected WithEvents DIV1 As System.Web.UI.HtmlControls.HtmlGenericControl
Protected WithEvents lblHtmlsTitle As System.Web.UI.HtmlControls.HtmlGenericControl
Protected WithEvents lblVersion As System.Web.UI.WebControls.Label
Protected WithEvents ValidationSummary1 As System.Web.UI.WebControls.ValidationSummary
Protected WithEvents RequiredFieldValidator1 As System.Web.UI.WebControls.RequiredFieldValidator
Protected WithEvents Label1 As System.Web.UI.WebControls.Label
Protected WithEvents btnOk As System.Web.UI.WebControls.Button
Protected WithEvents txtPWD As System.Web.UI.WebControls.TextBox
Protected WithEvents btnCancel As System.Web.UI.WebControls.Button
Protected WithEvents Label2 As System.Web.UI.WebControls.Label
Protected WithEvents RequiredFieldValidator2 As System.Web.UI.WebControls.RequiredFieldValidator
Protected WithEvents lblErrMessage As System.Web.UI.HtmlControls.HtmlGenericControl
Protected WithEvents txtUser As System.Web.UI.WebControls.TextBox
Protected WithEvents lblServer As System.Web.UI.WebControls.Label
Protected WithEvents Button1 As System.Web.UI.WebControls.Button
Protected WithEvents Button2 As System.Web.UI.HtmlControls.HtmlInputButton
Protected WithEvents btnRegister As System.Web.UI.WebControls.Button
Protected WithEvents btnEnd As System.Web.UI.WebControls.Button
'HINWEIS: Die folgende Platzhalterdeklaration ist für den Web Form-Designer erforderlich.
'Nicht löschen oder verschieben.
Private designerPlaceholderDeclaration As System.Object
Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init
'CODEGEN: Dieser Methodenaufruf ist für den Web Form-Designer erforderlich
'Verwenden Sie nicht den Code-Editor zur Bearbeitung.
InitializeComponent()
End Sub
#End Region
#Region "Form"
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
' Hier Benutzercode zur Seiteninitialisierung einfügen
If Not IsPostBack Then
With lblVersion
Dim aInfo As New AssemblyInfo
Me.lblHtmlsTitle.InnerText = aInfo.Title
Dim strFrVersion As String
If System.Environment.Version.ToString = "1.1.4322.573" Then
strFrVersion = "1.1"
ElseIf System.Environment.Version.ToString = "1.1.4322.2032" OrElse System.Environment.Version.ToString = "1.1.4322.2300" Then
strFrVersion = "1.1 SP1"
Else
strFrVersion = "?"
End If
.Text = String.Format("Version {0}", aInfo.Version) & " ASP.Net 2003 " & strFrVersion & " - W XP " & "04'2006" & vbCrLf & "Copyright by " & aInfo.Copyright
End With
Me.txtUser.Text = System.Environment.UserName
PstrLoginUser = System.Environment.UserDomainName & Slash & System.Environment.UserName
Dim strServerName As String
Dim errMsg As String
If Utility.DBConnection(strServerName, errMsg) = True Then
Me.lblServer.Text = "Aktueller Server ist : " & strServerName & " <br> " & "Angemeldet ist: " & PstrLoginUser & " - " & PMySecurity.ToString
Else
Me.lblServer.Text = "Angemeldet ist: " & PstrLoginUser & " - " & PMySecurity.ToString
End If
End If
Dim MyPage As Page = CType(Me, Page)
Utility.SetFocus(MyPage, Me.txtUser)
End Sub
#End Region
Antworten
Vorsicht bei der Eingabe: Die Zeichen ' oder -- sind nicht erlaubt!