I am using the latest Aspose.Pdf.net lib, I am upgraded from Aspose.Pdf.kit
foreach (Field field in pdfLetter.Document.Form)
{
string shortFieldName;
const string fieldPrefix = "TopmostSubform[0]";
shortFieldName = field.FullName;
if (shortFieldName.Equals(SignatureFieldName))
{
if (!string.IsNullOrEmpty(signatureImageFilename))
{
SignatureField sf = field as SignatureField;
if (sf != null)
{
//pdfLetter.FillImageField(fieldName, signatureImageFilename);
int signaturePage = field.PageIndex;
//create image stamp
ImageStamp imageStamp = new ImageStamp(signatureImageFilename);
imageStamp.Background = false;
imageStamp.XIndent = sf.Rect.LLX;
imageStamp.YIndent = sf.Rect.LLY;
imageStamp.Height = sf.Rect.Height;
imageStamp.Width = sf.Rect.Width;
//add stamp to particular page
pdfLetter.Document.Pages[signaturePage].AddStamp(imageStamp);
}
}
}
}