Share via


Report.addDesign Method

Definition

Overloads

addDesign()

Creates a reportDesign that belongs to a report.

addDesign(String)
addDesign(String, Object[])

addDesign()

Creates a reportDesign that belongs to a report.

public:
 virtual Dynamics::AX::Application::ReportDesign ^ addDesign();
public virtual Dynamics.AX.Application.ReportDesign addDesign ();
abstract member addDesign : unit -> Dynamics.AX.Application.ReportDesign
override this.addDesign : unit -> Dynamics.AX.Application.ReportDesign
Public Overridable Function addDesign () As ReportDesign

Returns

The created reportDesign.

Remarks

The buffer argument can be a container created by the pack method.

This job demonstrates how addDesign can be used to generate a design that is a copy of another design.

static void demoAddDesign(args a) 
{  
    report r1; 
    report r2; 
    reportDesign rd; 
    reportSection rs; 
    reportRun rr; 
    container c; 
    // Create a simple report r1. 
    r1 = new report(); 
    rd = r1.addDesign("Design1"); 
    rs = rd.addProgrammableSection(1); 
    rs.addTextControl("Hello world"); 
    c = rd.Pack(); // make a container containing r1's design 
    // Create a report r2 having a design that is a copy of r1's design. 
    r2 = new report(); 
    r2.AddDesign("design2", c); 
    // Run the report. 
    rr = new reportRun(r2, "design2"); 
    // Run the sysPrintForm form. 
    if (rr.prompt()) 
    { 
        // Execute the programableSection. 
        rr.execute(1);  
        // Print report to the target, such as printer or screen. 
        rr.print();    
    } 
}

Applies to

addDesign(String)

public:
 virtual Dynamics::AX::Application::ReportDesign ^ addDesign(System::String ^ text1);
public virtual Dynamics.AX.Application.ReportDesign addDesign (string text1);
abstract member addDesign : string -> Dynamics.AX.Application.ReportDesign
override this.addDesign : string -> Dynamics.AX.Application.ReportDesign
Public Overridable Function addDesign (text1 As String) As ReportDesign

Parameters

text1
String

Returns

Applies to

addDesign(String, Object[])

public:
 virtual Dynamics::AX::Application::ReportDesign ^ addDesign(System::String ^ _name, cli::array <System::Object ^> ^ _buffer);
public virtual Dynamics.AX.Application.ReportDesign addDesign (string _name, object[] _buffer);
abstract member addDesign : string * obj[] -> Dynamics.AX.Application.ReportDesign
override this.addDesign : string * obj[] -> Dynamics.AX.Application.ReportDesign
Public Overridable Function addDesign (_name As String, _buffer As Object()) As ReportDesign

Parameters

_name
String

Lets the design have the contents given by buffer.

_buffer
Object[]

Lets the design have the contents given by buffer.

Returns

Applies to