![]() |
|
| |||||||
|
| | Seçenekler |
|
#1
| |||
| | |||
VB.net İle e-Mail Gönderimi‘Tüm kodları Verdim. ‘Kopyala yapıştır ile işleme devam edin. ‘H.Bilal ALTIPARMAK ‘SEVGİLERİMLE Imports System.Web.Mail Public Class email Inherits System.Windows.Forms.Form #Region ” Windows Form Designer generated code “ Public Sub New() MyBase.New() ’This call is required by the Windows Form Designer. InitializeComponent() ’Add any initialization after the InitializeComponent() call End Sub ’Form overrides dispose to clean up the component list. Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean) If disposing Then If Not (components Is Nothing) Then components.Dispose() End If End If MyBase.Dispose(disposing) End Sub ’Required by the Windows Form Designer Private components As System.ComponentModel.IContainer ’NOTE: The following procedure is required by the Windows Form Designer ’It can be modified using the Windows Form Designer. ’Do not modify it using the code editor. Friend WithEvents Label1 As System.Windows.Forms.Label Friend WithEvents Label2 As System.Windows.Forms.Label Friend WithEvents Label3 As System.Windows.Forms.Label Friend WithEvents TextBox2 As System.Windows.Forms.TextBox Friend WithEvents TextBox3 As System.Windows.Forms.TextBox Friend WithEvents Button1 As System.Windows.Forms.Button Friend WithEvents Button2 As System.Windows.Forms.Button Friend WithEvents linkben As System.Windows.Forms.LinkLabel <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent() Me.Label1 = New System.Windows.Forms.Label() Me.Label2 = New System.Windows.Forms.Label() Me.Label3 = New System.Windows.Forms.Label() Me.TextBox2 = New System.Windows.Forms.TextBox() Me.TextBox3 = New System.Windows.Forms.TextBox() Me.Button1 = New System.Windows.Forms.Button() Me.Button2 = New System.Windows.Forms.Button() Me.linkben = New System.Windows.Forms.LinkLabel() Me.SuspendLayout() ’ ’Label1 ’ Me.Label1.AutoSize = True Me.Label1.Location = New System.Drawing.Point(6, 40) Me.Label1.Name = “Label1″ Me.Label1.Size = New System.Drawing.Size(118, 13) Me.Label1.TabIndex = 0 Me.Label1.Text = “Gideceği e-Mail Adresi” ’ ’Label2 ’ Me.Label2.AutoSize = True Me.Label2.Location = New System.Drawing.Point(80, 64) Me.Label2.Name = “Label2″ Me.Label2.Size = New System.Drawing.Size(37, 13) Me.Label2.TabIndex = 1 Me.Label2.Text = “Konu :” ’ ’Label3 ’ Me.Label3.AutoSize = True Me.Label3.Location = New System.Drawing.Point(8, 92) Me.Label3.Name = “Label3″ Me.Label3.Size = New System.Drawing.Size(35, 13) Me.Label3.TabIndex = 2 Me.Label3.Text = “label3″ ’ ’TextBox2 ’ Me.TextBox2.Location = New System.Drawing.Point(120, 61) Me.TextBox2.Name = “TextBox2″ Me.TextBox2.Size = New System.Drawing.Size(256, 20) Me.TextBox2.TabIndex = 4 Me.TextBox2.Text = “” ’ ’TextBox3 ’ Me.TextBox3.Location = New System.Drawing.Point(3, 110) Me.TextBox3.Multiline = True Me.TextBox3.Name = “TextBox3″ Me.TextBox3.Size = New System.Drawing.Size(376, 248) Me.TextBox3.TabIndex = 5 Me.TextBox3.Text = “” ’ ’Button1 ’ Me.Button1.Location = New System.Drawing.Point(222, 365) Me.Button1.Name = “Button1″ Me.Button1.TabIndex = 6 Me.Button1.Text = “Button1″ ’ ’Button2 ’ Me.Button2.DialogResult = System.Windows.Forms.DialogResult.Cancel Me.Button2.Location = New System.Drawing.Point(305, 365) Me.Button2.Name = “Button2″ Me.Button2.TabIndex = 7 Me.Button2.Text = “Kapat” ’ ’linkben ’ Me.linkben.ActiveLinkColor = System.Drawing.Color.Blue Me.linkben.AutoSize = True Me.linkben.Font = New System.Drawing.Font(”Tahoma”, 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(162, Byte)) Me.linkben.LinkColor = System.Drawing.Color.Red Me.linkben.Location = New System.Drawing.Point(128, 40) Me.linkben.Name = “linkben” Me.linkben.Size = New System.Drawing.Size(99, 14) Me.linkben.TabIndex = 9 Me.linkben.TabStop = True Me.linkben.Text = “” ’ ’ Me.AcceptButton = Me.Button1 Me.AutoScaleBaseSize = New System.Drawing.Size(5, 13) Me.CancelButton = Me.Button2 Me.ClientSize = New System.Drawing.Size(384, 392) Me.Controls.AddRange(New System.Windows.Forms.Control() {Me.linkben, Me.Button2, Me.Button1, Me.TextBox3, Me.TextBox2, Me.Label3, Me.Label2, Me.Label1}) Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWind ow Me.Name = “email” Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterParen t Me.Text = “E-mail Gönder” Me.ResumeLayout(False) End Sub #End Region Private Sub email_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load TextBox2.Text = “” TextBox3.Text = “” Label1.Text = “Gideceği e-Mail Adresi” Label2.Text = “Konu” Label3.Text = “Mesaj Metni” Button1.Text = “Gönder” End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim mes As New MailMessage() mes.To = linkben.Text mes.From = “” mes.subject = TextBox2.Text mes.body = TextBox3.Text mes.bodyformat = mailformat.text SmtpMail.SmtpServer = “mail.ymyo.net” ‘BU KISIMA MAİL SERVER ADINI YAZIN SmtpMail.Send(mes) MsgBox(”e-MAİL Başarıyla Gönderildi!!!”, MsgBoxStyle.Information, “GÖNDERME MESAJI”) Try Catch a As Exception MsgBox(”e-MAİL GÖNDERİLEMEDİ!!!”, MsgBoxStyle.OKOnly) End Try End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Me.Close() End Sub End class |
![]() |
| Arama Etiketleri: gonderimi, vbnet |
| Seçenekler | |
| |
Benzer Konular | ||||
| Konu | Konu Açanlar | Forum | Cevaplar | Güncel Mesajlar |
| FTP Programi Kullanimi ve Dosya gönderimi | egitimbilgisi | Yeni Başlayanlara WebmasterSitesi | 0 | 30-05-2008 10:29 |
| siteadı.com lu mail | mixnet | Webmaster Genel Konular | 3 | 16-03-2008 09:39 |
| 452 Multi Mail | Miliotta | PHP scriptler | 0 | 12-03-2008 08:45 |
| E-MAIL Nedir? | kadınca | Webmaster Sözlügü | 0 | 23-02-2008 07:21 |
| ASP.NET ile E-Mail yollamak | B737 | .NET programcılığı | 0 | 24-01-2008 01:46 |
![]() | ![]() |