CMS 1500 Form – Modify Form Fields Before Printing

Index

    Modify Form Fields Before Printing

    Certain form fields properties may need slight adjustment before printing. The BeforePrint event will be raised before the form is sent to the printer. Field properties like width, height, x y positions etc can be modified.

    Example

    CMS1500Form cmsForm = new CMS1500Form();
     
    cmsForm.BeforePrint += cmsForm_BeforePrint;
     
    private void cmsForm_BeforePrint(object sender, FormEventArgs e)
    {
        //e.Cells has all fields that will be send to printer.
        //The field properties can be modified
        e.Cells[0].X = 12;
        e.Cells[0].Y = 13;
        e.Cells[1].Width = 3;
        e.Cells[1].Height = 0.5;
    }
    in CMS – 1500 Form
    Did this article answer your question?