Board index » cppbuilder » SMTP Server with Indy
carmelo
![]() CBuilder Developer |
SMTP Server with Indy2005-09-15 03:27:28 PM cppbuilder53 I'm trying to use the code in the example SMTPRelay on the Indy library, but i'm having problems... The problem is that I was not able to extract, from the DNS query reply, the MX record... I tried to translate the Delphi code contained in the example, in BCB code, but I was not able to extract the MX record. Here is the code I used: if ( IdDNSResolver1->QueryResult->Count>0 ) { for (int i = 0; i<= IdDNSResolver1->QueryResult->Count - 1; i++) { if (IdDNSResolver1->QueryResult->Items[i]->RecType == qtMX ) { TMXRecord *MXR = new TMXRecord(IdDNSResolver1->QueryResult); MX = MXR->ExchangeServer; Edit1->Text = MX; delete MXR; } } } What do you think?? What can I do? Thank you very much!! |