Hi, I have a sequential file which contains Email Ids.
I have to write a routine, which should fetches the email id from the sequential file and mail has to be send dynamically to that email id which has been fetched earlier.
i have written a code like:
$INCLUDE DSINCLUDE JOBCONTROL.H
sleep 20
Dummy=0
vParamFile = '/dir1/folder/filename.txt'
OpenSeq vParamFile To FileVar Else
Call DSLogWarn("Cannot open ":vParamFile , "Cannot Open ParamFile")
End
loop
ReadSeq Dummy From FileVar Else Exit ;
code = DSSendMail("From:me@here.com\nTo:Dummy\nSubject:Hi ya\nBody:Line1")
Call DSLogInfo(Dummy, "Job Control")
repeat
CloseSeq FileVar
But the "ReadSeq Dummy From FileVar Else Exit " the dummy value is not getting passed to the TO address in the DSSendmail command.
let me know how to pass the to address to the DSSendmail command,
thanks,
How to pass "TO Email" address dynamically in DSSe
Moderators: chulett, rschirm, roy
should be:
Code: Select all
code = DSSendMail("From:me@here.com\nTo:": Dummy :"\nSubject:Hi ya\nBody:Line1")
Mamu Kim
Thanks Duke
Thanks a lot Duke, Its working fine now.kduke wrote:should be:
Code: Select all
code = DSSendMail("From:me@here.com\nTo:": Dummy :"\nSubject:Hi ya\nBody:Line1")