BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How I can send emails directly from my PC to recipient mailb

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Internet Winsock
View previous topic :: View next topic  
Author Message
Carl
Guest





PostPosted: Tue Feb 24, 2004 11:19 am    Post subject: How I can send emails directly from my PC to recipient mailb Reply with quote



I want send emails directly from my PC to recipient mailboxes without use
the SMTP of my ISP nor other SMTP outside my PC.

Thank you
Carl


Back to top
Lee_Nover
Guest





PostPosted: Tue Feb 24, 2004 12:01 pm    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote



check Indy SMTPRelay demo


"Carl" <pleasenospam (AT) ciudad (DOT) com.ar> wrote

Quote:
I want send emails directly from my PC to recipient mailboxes without use
the SMTP of my ISP nor other SMTP outside my PC.

Thank you
Carl





Back to top
Martin James
Guest





PostPosted: Tue Feb 24, 2004 12:30 pm    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote




"Carl" <pleasenospam (AT) ciudad (DOT) com.ar> wrote

Quote:
I want send emails directly from my PC to recipient mailboxes without use
the SMTP of my ISP nor other SMTP outside my PC.

I use TidDNSResolver to get a name for the recipients MX server & them use
TidSMTP to send to it. It works for our clients.

Rgds,
Martin



Back to top
Carl
Guest





PostPosted: Wed Feb 25, 2004 1:47 am    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote

Thank you Lee, THIS WORK FINE !

"Lee_Nover" <Lee_Nover[nospam]@delphi-si.com> escribió en el mensaje
news:403b3d1f$1 (AT) newsgroups (DOT) borland.com...
Quote:
check Indy SMTPRelay demo


"Carl" <pleasenospam (AT) ciudad (DOT) com.ar> wrote in message
news:403b3377 (AT) newsgroups (DOT) borland.com...
I want send emails directly from my PC to recipient mailboxes without
use
the SMTP of my ISP nor other SMTP outside my PC.

Thank you
Carl




Back to top
Carl
Guest





PostPosted: Wed Feb 25, 2004 3:55 am    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote

Thank you and

How I can get the TidDNSResolver.HOST ?

I want not put this with my hand

Thank you

"Martin James" <mjames_falcon (AT) dial (DOT) pipex.com> escribió en el mensaje
news:403b43df (AT) newsgroups (DOT) borland.com...
Quote:

"Carl" <pleasenospam (AT) ciudad (DOT) com.ar> wrote in message
news:403b3377 (AT) newsgroups (DOT) borland.com...
I want send emails directly from my PC to recipient mailboxes without
use
the SMTP of my ISP nor other SMTP outside my PC.

I use TidDNSResolver to get a name for the recipients MX server & them use
TidSMTP to send to it. It works for our clients.

Rgds,
Martin





Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Wed Feb 25, 2004 6:25 am    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote

"Carl" <pleasenospam (AT) ciudad (DOT) com.ar> wrote


Quote:
How I can get the TidDNSResolver.HOST ?

Use the DNS host(s) that are provided by your ISP. Either provide a
configuration screen to your program so that you can program in the host(s)
and save it/them for later use, or alternatively you will have to retrieve
the current host(s) from your modem's network adapter directly while you are
actually connected online, via the GetAdaptersInfo() function.


Gambit



Back to top
Carl
Guest





PostPosted: Wed Feb 25, 2004 11:54 am    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote

I sorry, I not found GetAdaptersInfo(), I have Delphi 7
Have you an example for GetAdaptersInfo() ?

Thank you

"Remy Lebeau (TeamB)" <gambit47.no.spam (AT) no (DOT) spam.yahoo.com> escribió en el
mensaje news:403c3ded (AT) newsgroups (DOT) borland.com...
Quote:

"Carl" <pleasenospam (AT) ciudad (DOT) com.ar> wrote in message
news:403c1d0e (AT) newsgroups (DOT) borland.com...

How I can get the TidDNSResolver.HOST ?

Use the DNS host(s) that are provided by your ISP. Either provide a
configuration screen to your program so that you can program in the
host(s)
and save it/them for later use, or alternatively you will have to retrieve
the current host(s) from your modem's network adapter directly while you
are
actually connected online, via the GetAdaptersInfo() function.


Gambit





Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Wed Feb 25, 2004 9:28 pm    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote


"Carl" <pleasenospam (AT) ciudad (DOT) com.ar> wrote

Quote:
I sorry, I not found GetAdaptersInfo()

It is a Win32 API function, not an Indy function.


Gambit




Back to top
Carl
Guest





PostPosted: Thu Feb 26, 2004 4:42 am    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote

Ok Remy,
If this posible may you give me an example for to use the Win32 API function
GetAdaptersInfo() for to get the DNSs and what unit I need to put ?

I look all the help but I not found an example

Thank you



Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Thu Feb 26, 2004 8:37 am    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote


"Carl" <pleasenospam (AT) ciudad (DOT) com.ar> wrote


Quote:
If this posible may you give me an example for to use the
Win32 API function GetAdaptersInfo() for to get the DNSs

Whoops, my bad, I meant GetNetworkParams(), not GetAdpatersInfo(). Try the
following (untested):

uses Windows;

const
MAX_HOSTNAME_LEN = 128;
MAX_DOMAIN_NAME_LEN = 128;
MAX_SCOPE_ID_LEN = 256;

type
TIPAddressString = packed record
String: Array[0..15] of Char;
end;
TIPMaskString = TIPAddressString;

PIPAddrString = ^TIPAddrString;
TIPAddrString = packed record
Next: PIPAddrString;
IpAddress: TIPAddressString;
IpMask: TIPMaskString;
Context: DWORD;
end;

PFixedInfo = ^TFixedInfo;
TFixedInfo = packed record
HostName: Array[0..MAX_HOSTNAME_LEN + 3] of Char;
DomainName: Array[0..MAX_DOMAIN_NAME_LEN + 3] of Char;
CurrentDnsServer: PIPAddrString;
DnsServerList: TIPAddrString;
NodeType: UINT;
ScopeId: Array[0..MAX_SCOPE_ID_LEN + 3] of Char;
EnableRouting: UINT;
EnableProxy: UINT;
EnableDns: UINT;
end;

function GetNetworkParams(pFixedInfo: PFixedInfo; var OutBufLen:
ULONG): DWORD; stdcall; external 'IPHlpApi.dll' name 'GetNetworkParams';



uses System;

var
BufLen: DWORD;
FixedInfo: PFixedInfo;
DnsServer: PIPAddrString;
begin
BufLen := 0;
if GetNetworkParams(nil, BufLen) = ERROR_BUFFER_OVERFLOW then
begin
GetMem(FixedInfo, BufLen);
try
if GetNetworkParams(FixedInfo, BufLen) = ERROR_SUCCESS then
begin
DnsServer := @(FixedInfo^.DnsServerList);
repeat
// use DnsServer^.IpAddress.String as needed...
DnsServer := DnsServer.Next;
until DnsServer = nil;
end;
finally
FreeMem(FixedInfo);
end;
end;
end;


Gambit



Back to top
Carl
Guest





PostPosted: Thu Feb 26, 2004 6:47 pm    Post subject: Re: How I can send emails directly from my PC to recipient m Reply with quote

THANK YOUUUU Remy THIS WORK FINE !

I only change
TIPAddressString = {packed} record
String: Array[0..15] of Char; // String is reserved
word
with

TIPAddressString = {packed} record
sString: Array[0..15] of Char;

Thank you


Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Internet Winsock All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.