The Initialize method initializes a thumbnail control with a reference to the PDF control that it will reflect from that point onwards.
void Initialize( object pDispatch );
pDispatch
This holds a reference to the Amyuni CreactiveX PDF control that will be associated with this thumbnail control.
This method returns 0 upon success; returns another value upon failure. In a .NET environment, nothing is returned upon success, and an exception is thrown upon failure.
The example below shows the implementation of a button-Click handler on a form containing both a PDF control and a thumbnail control. The button causes a PDF document to be loaded into the control and then initializes the thumbnail control with it.
private void buttonLoadFile_Click(object sender, EventArgs e)
{
//iacThumbnailView1 is a control on your form
// Open a PDF document from file
System.IO.FileStream fileO = new System.IO.FileStream("file1.pdf", FileMode.Open, FileAccess.Read, FileShare.Read);
pdfCreator1.Document.Open(fileO, "");
iacThumbnailView1.Initialize(pdfCreator1);
iacThumbnailView1.RedrawAllThumbs();
}