Änderungen

This commit is contained in:
ja
2021-11-16 16:39:36 +01:00
parent 41d2c3d8ed
commit f9107e9aba

View File

@@ -3,14 +3,14 @@ Partial Class Customers_Default
Inherits System.Web.UI.Page Inherits System.Web.UI.Page
Dim Kdnrtext As String = String.Empty Dim Kdnrtext As String = String.Empty
Protected Sub Page_Load(sender As Object, e As EventArgs) Protected Sub Page_Load(sender As Object, e As EventArgs)
If Me.Page.User.Identity.IsAuthenticated Then If Me.Page.User.Identity.IsAuthenticated And String.Equals(Me.Page.User.Identity.Name, "Admin") = True Then
Try Try
Kdnrtext = Session.Item("CustomerID") Kdnrtext = Session.Item("CustomerID")
Catch A As UnauthorizedAccessException When String.IsNullOrEmpty(Kdnrtext) Catch A As UnauthorizedAccessException When String.IsNullOrEmpty(Kdnrtext)
MsgBox("Dieser Bereich ist nicht gestattet! Ein Fehler ist bei der Validierung der ID aufgetreten! Bitte erneut versuchen!", MsgBoxStyle.Information, "Error in User Area!") MsgBox("Dieser Bereich ist nicht gestattet! Ein Fehler ist bei der Validierung der ID aufgetreten! Bitte erneut versuchen!", MsgBoxStyle.Information, "Error in User Area!")
End Try End Try
Else Else
FormsAuthentication.RedirectToLoginPage() Response.Redirect("../login..Error.aspx?Par1=" + VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt("Default.aspx"))
End If End If
If Page.IsPostBack = True Then If Page.IsPostBack = True Then
Page.MaintainScrollPositionOnPostBack = True Page.MaintainScrollPositionOnPostBack = True