PrintDocument for WinForms | ComponentOne
C1.Win.PrintPreview.4.5.2 Assembly / C1.Win.C1Preview.Design Namespace / SampleC1PrintDocument Class / RenderDirect Method / RenderDirect(Unit,Unit,RenderObject,Object,Object) Method
The horizontal (X) coordinate at which to render the object (cannot be auto).
The vertical (Y) coordinate at which to render the object (cannot be auto).
The C1.C1Preview.RenderObject object to render.
The width of the object (if null, auto is used).
The height of the object (if null, auto is used).

In This Topic
    RenderDirect(Unit,Unit,RenderObject,Object,Object) Method
    In This Topic
    Adds a C1.C1Preview.RenderObject to the C1.C1Preview.C1PrintDocument.Body of the current document at a specific position on the current page, and resolves it.

    This method can only be used if C1.C1Preview.C1PrintDocument.IsStartEndDocMode is true.

    Syntax
    'Declaration
     
    Public Overloads Function RenderDirect( _
       ByVal x As Unit, _
       ByVal y As Unit, _
       ByVal ro As RenderObject, _
       ByVal width As Object, _
       ByVal height As Object _
    ) As Boolean
    public bool RenderDirect( 
       Unit x,
       Unit y,
       RenderObject ro,
       object width,
       object height
    )

    Parameters

    x
    The horizontal (X) coordinate at which to render the object (cannot be auto).
    y
    The vertical (Y) coordinate at which to render the object (cannot be auto).
    ro
    The C1.C1Preview.RenderObject object to render.
    width
    The width of the object (if null, auto is used).
    height
    The height of the object (if null, auto is used).

    Return Value

    true if no warnings were generated by this call, false otherwise.
    Remarks
    The specified coordinates (x and y) are assigned to the C1.C1Preview.RenderObject.X and C1.C1Preview.RenderObject.Y properties of the passed object.

    The specified dimensions (width and height) are assigned to the C1.C1Preview.RenderObject.Width and C1.C1Preview.RenderObject.Height properties of the passed object.

    As all other RenderBlock..., RenderDirect... and RenderInline... methods, This method can only be used between calls to C1.C1Preview.C1PrintDocument.StartDoc and C1.C1Preview.C1PrintDocument.EndDoc on the current document, i.e. when the C1.C1Preview.C1PrintDocument.IsStartEndDocMode property is true.

    Do not use this method if the document is generated with a call to the C1.C1Preview.C1PrintDocument.Generate method.

    See Also