Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.

To mail or not to mail... Mail program u VB6

[es] :: Visual Basic 6 :: To mail or not to mail... Mail program u VB6

[ Pregleda: 4115 | Odgovora: 8 ] > FB > Twit

Postavi temu Odgovori

Autor

Pretraga teme: Traži
Markiranje Štampanje RSS

Episonage

Član broj: 125585
Poruke: 4
*.beogrid.net.



Profil

icon To mail or not to mail... Mail program u VB616.12.2006. u 14:32 - pre 211 meseci
Skinuo sam gomilu primera "kako napraviti prost mail program u vb", ali svaki od njih je sve, samo nije prost. Hocu da napravim programce koje ce da posalje mail na datu adresu, bez attachmenta, ako je moguce sa skrivenom adresom... Moze li neko da mi pomogne?
 
Odgovor na temu

icobh
Igor Pejašinović
Network Admin
Navigo SC d.o.o.
Banja Luka

Član broj: 18738
Poruke: 1319
*.inecco.net.

Sajt: www.nsc.ba


+4 Profil

icon Re: To mail or not to mail... Mail program u VB616.12.2006. u 15:13 - pre 211 meseci
Pogledaj ANSMTP
I ♥ ♀

Ovaj post je zlata vrijedan!
 
Odgovor na temu

Episonage

Član broj: 125585
Poruke: 4
*.beogrid.net.



Profil

icon Re: To mail or not to mail... Mail program u VB616.12.2006. u 16:05 - pre 211 meseci
Ummm..... Sta je ANSMTP ?
 
Odgovor na temu

icobh
Igor Pejašinović
Network Admin
Navigo SC d.o.o.
Banja Luka

Član broj: 18738
Poruke: 1319
*.inecco.net.

Sajt: www.nsc.ba


+4 Profil

icon Re: To mail or not to mail... Mail program u VB616.12.2006. u 16:41 - pre 211 meseci
http://www.emailarchitect.net/WebApp/SMTPCOM/
I ♥ ♀

Ovaj post je zlata vrijedan!
 
Odgovor na temu

Aleksandar Ružičić
Software Architect, Appricot d.o.o.
Beograd

Član broj: 26939
Poruke: 2881

Jabber: krckoorascic@gmail.com
Sajt: krcko.net


+44 Profil

icon Re: To mail or not to mail... Mail program u VB616.12.2006. u 23:48 - pre 211 meseci
Citat:
Episonage: ... ako je moguce sa skrivenom adresom...

ovo mi zvuci na spam ;)
 
Odgovor na temu

icobh
Igor Pejašinović
Network Admin
Navigo SC d.o.o.
Banja Luka

Član broj: 18738
Poruke: 1319
*.inecco.net.

Sajt: www.nsc.ba


+4 Profil

icon Re: To mail or not to mail... Mail program u VB617.12.2006. u 10:34 - pre 211 meseci
Očigledno ali ANSMTP je sasvim dozvoljena stvar...
I ♥ ♀

Ovaj post je zlata vrijedan!
 
Odgovor na temu

Episonage

Član broj: 125585
Poruke: 4
*.beogrid.net.



Profil

icon Re: To mail or not to mail... Mail program u VB617.12.2006. u 12:24 - pre 211 meseci
Nah, nisam ja tip koji bi gubio vreme na spamovanje nevinih ljudi, i ja mrzim kad me spamuju... Al' postoji razlog...
 
Odgovor na temu

icobh
Igor Pejašinović
Network Admin
Navigo SC d.o.o.
Banja Luka

Član broj: 18738
Poruke: 1319
*.inecco.net.

Sajt: www.nsc.ba


+4 Profil

icon Re: To mail or not to mail... Mail program u VB617.12.2006. u 12:59 - pre 211 meseci
Imam ja jedan gotov fin malen programčić sa sorsom, koji šalje mail preko tvog ISP-a, mislim mail servera ali u adresu možeš da upišeš šta god hoćeš! Ja najčešće pišem "Stoka i Nered". Nemam pojma zašto ali se nekako pronalazim u tom...
I ♥ ♀

Ovaj post je zlata vrijedan!
 
Odgovor na temu

zWest
Aleksandar
student
Banja Luka

Član broj: 17852
Poruke: 21
*.dialup.blic.net.

Sajt: www.blhost.net


Profil

icon Re: To mail or not to mail... Mail program u VB618.12.2006. u 20:15 - pre 210 meseci
program lako napraviti bez atachmenta uz Winsock kontrolu mada mozes i sa atachmentom samo je malo komplikovanije

recimo ovo je moj programcic za to (nikad ga nisam finalizovao nazalost ali radi)

Mail program

a evo i jedan code :



Code:
Dim Response As String
Dim Start As Single, Tmr As Single


Sub SendEmail(MailServerName As String, FromName As String, FromEmailAddress As String, ToName As String, ToEmailAddress As String, EmailSubject As String, EmailBodyOfMessage As String)
Dim DateNow As String
Dim first As String, Second As String, Third As String
Dim Fourth As String, Fifth As String, Sixth As String
Dim Seventh As String
With Winsock1
    If .State = sckClosed Then ' Check to see if socket is closed
        DateNow = Format(Date, "Ddd") & ", " & Format(Date, "dd Mmm YYYY") & " " & Format(Time, "hh:mm:ss") & "" & " -0600"
        first = "mail from: " & FromEmailAddress & vbCrLf ' Get who's sending E-Mail address
        Second = "rcpt to: " & ToEmailAddress & vbCrLf ' Get who mail is going to
        Third = "Date: " & DateNow & vbCrLf ' Date when being sent
        Fourth = "From: """ & FromName & """ <" & FromEmailAddress & ">" + vbCrLf ' Who's Sending
        Fifth = "To: " & ToNametxt & vbCrLf ' Who it going to
        Sixth = "Subject: " & EmailSubject & vbCrLf ' Subject of E-Mail
        Seventh = EmailBodyOfMessage & vbCrLf ' E-mail message body
        Ninth = "X-Mailer: STMP Sender" & vbCrLf ' What program sent the e-mail, customize this
        .LocalPort = 0 ' Must set local port to 0 (Zero) or you can only send 1 e-mail per program start
        .Protocol = sckTCPProtocol ' Set protocol for sending
        .RemoteHost = MailServerName ' Set the server address
        .RemotePort = 25 ' Set the SMTP Port
        .Connect ' Start connection
        WaitFor ("220")
        StatusTxt.Caption = "Connecting...."
        .SendData ("HELO EnterComputerNameHere" & vbCrLf)
        WaitFor ("250")
        StatusTxt.Caption = "Connected"

        .SendData (first)
        StatusTxt.Caption = "Sending Message"

        WaitFor ("250")
        .SendData (Second)
        WaitFor ("250")
        .SendData ("data" & vbCrLf)
        WaitFor ("354")
        .SendData (Fourth & Third & Ninth & Fifth & Sixth & vbCrLf)
        .SendData (Seventh & vbCrLf)
        .SendData ("." & vbCrLf)
        WaitFor ("250")
        .SendData ("quit" & vbCrLf)
        StatusTxt.Caption = "Disconnecting"

        WaitFor ("221")
        .Close
    Else
        MsgBox (Str(.State))
    End If
End With
End Sub


Sub WaitFor(ResponseCode As String)
    Start = Timer ' Time event so won't get stuck in loop
    While Len(Response) = 0
        Tmr = Start - Timer
        DoEvents ' Let System keep checking for incoming response **IMPORTANT**
        If Tmr > 50 Then ' Time in seconds to wait
            MsgBox "SMTP service error, timed out while waiting for response", 64, MsgTitle
            Exit Sub
        End If
    Wend
    While Left(Response, 3) <> ResponseCode
        DoEvents
        If Tmr > 50 Then
           MsgBox "SMTP service error, impromper response code. Code should have been: " + ResponseCode + " Code recieved: " + Response, 64, MsgTitle
           Exit Sub
        End If
    Wend
    Response = "" ' Sent response code to blank **IMPORTANT**
End Sub


Private Sub CmdSendMail_Click()
    SendEmail txtEmailServer.Text, txtFromName.Text, txtFromEmailAddress.Text, txtToEmailAddress.Text, txtToEmailAddress.Text, txtEmailSubject.Text, txtMessage.Text
    StatusTxt.Caption = "Mail Sent"
    Beep
    Close
End Sub

Private Sub Winsock1_DataArrival(ByVal bytesTotal As Long)
    Winsock1.GetData Response ' Check for incoming response *IMPORTANT*
End Sub



code nije moj ali je dostupan na netu besplatno
 
Odgovor na temu

[es] :: Visual Basic 6 :: To mail or not to mail... Mail program u VB6

[ Pregleda: 4115 | Odgovora: 8 ] > FB > Twit

Postavi temu Odgovori

Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.