(Go) Transition from Email.GetLinkedDomains to Email.LinkedDomains
Provides instructions for replacing deprecated GetLinkedDomains method calls with LinkedDomains. Note: This example requires Chilkat v11.0.0 or greater.
email := Email_Ref.html">chilkat.NewEmail()
// ...
// ...
// ------------------------------------------------------------------------
// The GetLinkedDomains method is deprecated:
sa := email.GetLinkedDomains()
if email.LastMethodSuccess() == false {
fmt.Println(email.LastErrorText())
email.DisposeEmail()
return
}
// ...
// ...
sa.DisposeStringArray()
// ------------------------------------------------------------------------
// Do the equivalent using LinkedDomains.
// Your application creates a new, empty StringTable_Ref.html">StringTable object which is passed
// in the last argument and filled upon success.
st := StringTable_Ref.html">chilkat.NewStringTable()
success := email.LinkedDomains(st)
if success == false {
fmt.Println(email.LastErrorText())
email.DisposeEmail()
st.DisposeStringTable()
return
}
email.DisposeEmail()
st.DisposeStringTable()
|