Parameters
profile |
name of the mailing profile |
propname |
name of the parameter of the mailing profile |
propvalue |
output parameter, value of the parameter of the mailing profile |
valsize |
size of the buffer for the value |
Since version
8.0
Description
Reads the value of the parameter of the specified mailing profile profile and stores it in the output buffer. Password for mail access and password for establishing phone connection cannot be get with this function.
If the propname parameter is not found in the profile, the function will return the 513 error. If the parameter in the profile has an empty value (this shouldn't occur if you're setting the profile in the 602SQL Client), the function will result normally and an empty string will be in the output parameter.
Function value
This function returns 0 if successful, the error number otherwise. The error number may also be found by the Sz_error
or Signalize
function.
Example
// is it a permanent type SMTP profile?
SET Err=MailGetProfileProp(profile,"SMTPServer",smtp_server,100);
// if yes, we make it temporary and replace the sender address from the permanent profile with another
IF Err=0 THEN
CALL MailCreateProfile("_temporary",TRUE);
CALL MailSetProfileProp("_temporary","SMTPServer",smtp_server);
CALL MailSetProfileProp("_temporary","MyAddress",whom);
See