Aspose::Words::MailMerging::IMailMergeDataSource interface

IMailMergeDataSource interface

Implement this interface to allow mail merge from a custom data source, such as a list of objects. Master-detail data is also supported.

class IMailMergeDataSource : public System::Object

Methods

MethodDescription
virtual GetChildDataSource(System::String)The Aspose.Words mail merge engine invokes this method when it encounters a beginning of a nested mail merge region.
virtual GetValue(System::String, System::SharedPtr<System::Object> &)Returns a value for the specified field name or false if the field is not found.
virtual MoveNext()Advances to the next record in the data source.
virtual get_TableName()Returns the name of the data source.

Remarks

When a data source is created, it should be initialized to point to BOF (before the first record). The Aspose.Words mail merge engine will invoke MoveNext to advance to next record and then invoke GetValue() for every merge field it encounters in the document or the current mail merge region.

See Also