You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
45 lines
2.0 KiB
45 lines
2.0 KiB
Public Class Berufsanfrage
|
|
Inherits System.Web.UI.Page
|
|
|
|
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
|
|
|
|
End Sub
|
|
|
|
Protected Sub RadButton1_Click(sender As Object, e As EventArgs) Handles RadButton1.Click
|
|
Dim mds As New DataSet
|
|
Dim dh As New clsDatahandling
|
|
|
|
mds = dh.Get_Tabledata("Select * from beruf where bezeichnung='" + Me.RadTextBox1.Text + "'", False, True)
|
|
If mds.Tables(0).Rows.Count > 0 Then
|
|
RadWindowManager1.RadAlert("Die erfasste Berufsbezeichnung ist bereits vorhanden. Bitte eingaben überprüfen", 330, 100, "Bestätigung", "alertCallBackFn", "~/Bilder/info.png")
|
|
End If
|
|
|
|
mds = dh.Get_Tabledata("Select * from Web_MailTexte where nreintrag=3", False, True)
|
|
Dim inhalt As String = mds.Tables(0).Rows(0).Item("Inhalt")
|
|
Dim betreff As String = mds.Tables(0).Rows(0).Item("Betreff")
|
|
inhalt = inhalt.Replace("[Beruf]", Me.RadTextBox1.Text)
|
|
|
|
mds.Tables.Clear()
|
|
mds = dh.Get_Tabledata("Select * from optionen where optionnr=6", False, True)
|
|
Dim Email As String = mds.Tables(0).Rows(0).Item("Inhalt")
|
|
|
|
mds.Tables.Clear()
|
|
Dim firma As New DataTable
|
|
firma = dh.Get_Firma(Session("Firmanr"))
|
|
|
|
inhalt = inhalt.Replace("[Firma]", firma.Rows(0).Item("NameZ1") + " " + firma.Rows(0).Item("NameZ2"))
|
|
inhalt = inhalt.Replace("[Strasse]", firma.Rows(0).Item("Strasse"))
|
|
inhalt = inhalt.Replace("[PLZ]", firma.Rows(0).Item("Plz"))
|
|
inhalt = inhalt.Replace("[Ort]", firma.Rows(0).Item("Ort"))
|
|
inhalt = inhalt.Replace("[Telefon]", firma.Rows(0).Item("Tel"))
|
|
inhalt = inhalt.Replace("[EMail]", firma.Rows(0).Item("EMail"))
|
|
|
|
Dim mailer As New clsSendMail
|
|
mailer.SendMailMessage("", Email, "", "", betreff, inhalt)
|
|
RadWindowManager1.RadAlert("Ihre Anfrage wurde erfolgreich übermittelt", 330, 100, "Bestätigung", "alertCallBackFn", "~/Bilder/info.png")
|
|
|
|
|
|
End Sub
|
|
|
|
|
|
End Class |