Link to home
Start Free TrialLog in
Avatar of danz67
danz67Flag for Italy

asked on

DELPHI 7 - AsyncPro SMS

hi,
use components AsyncPro to send sms via GSM phone.
Can i send a sms to many recipients, and use a custom from?
Thanks
Avatar of danz67
danz67
Flag of Italy image

ASKER

Today all is quiet :(
Avatar of Ferruccio Accalai
From the reference guide (http://tpapro.sourceforge.net/docs/APRO_ReferenceGuide.pdf page 870 (877 of the pdf))

Use OnNextMessage event to send another message
Set there the new Address and Message values and set NextMessageReady to true.
When the last message is sent then set there NextMessageReady to False.
The OnSessionFinish event then is fired (where you can show any finished message or do any other kind of stuff)

Avatar of danz67

ASKER

I tried and successfully sends the message to multiple addresses, when I finish I can not set to send "OnGSMComplete event" NextMessageReady to False.

Finally, if you use a memo addressed to read as I browse through the items?

Thankx
Avatar of danz67

ASKER

"Finally, if you use a memo addressed to read as I browse through the items?"

not respond to this, I know but forgot to do
ASKER CERTIFIED SOLUTION
Avatar of Ferruccio Accalai
Ferruccio Accalai
Flag of Italy image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Assuming the "i" start at 0 and finish at Memo1.Lines.Count, you can simplify a bit

I'll also call "i" CurrentMessage and assume MessageSendTo is a TStrings where the adress are , as these are probably global variables (or global to the form/datamodule) they'd better have a good name

Yet the idea is the same, good work Ferruccio !
NextMessageReady:= CurrentMessage < MessageSendTo.Count;
if NextMessageReady Then
 begin
  SMSAddress := MessageSendTo [CurrentMessage]; 
  Inc(CurrentMessage);
 end;

Open in new window

Avatar of danz67

ASKER

through Ferruccio68 everything works fine, but lacks the other response, that
Can I use a custom from?
If you never change it, it remains assigned as you did the first time.
Avatar of danz67

ASKER

how can I change it?
Maybe I'm misunderstanding the q.

In TADPGSMPhone there's not such FROM value, as it uses the GSM Phone interface, so the "From" is always stored by the phone