Below is a segment of code I am using to fill in a form. Each time through the loop i need to put an image in based on data from the database. There are two different images which are different sizes. When I put them in they scale to the size of the field, which is a button. I have even set the properties to neever scale.
I am looking for suggestions. Also is it possible to open a pdf in a PDF object then access the Form object from that one?
form_venueDetails = new Form(reportspath + "/templates/CafeScreen_Installed_Venues.pdf", reportspath + "/dynamicreports/" + basename + "_p" + pagenum.ToString() + ".pdf");
rowcount = dv.Count;
foreach (DataRowView dr in dv)
{
liveVenues.venuedetailssheetRow drTyped = (liveVenues.venuedetailssheetRow)dr.Row;
form_venueDetails.FillField(field_cafe + i.ToString("00"), drTyped.locationname);
form_venueDetails.FillImageField("screen_img_" + i.ToString("00"), reportspath + "/templates/screen_" + drTyped.screensize.ToString() + ".gif");
i += 1;
if (i > 12 && (((pagenum -1) * maxVenuesPerPage) + i) < rowcount)
{
form_venueDetails.FlattenAllFields();
form_venueDetails.Save();
i = 1;
pagenum += 1;
form_venueDetails = new Form(reportspath + "/templates/CafeScreen_Installed_Venues.pdf", reportspath + "/dynamicreports/" + basename + "_p" + pagenum.ToString() + ".pdf");
}
}
This message was posted using Aspose.Live 2 Forum