API Help
Eplan.EplApi.HEServices Namespace / Reports Class / CreateViewPlacements Method
Project
Collection of templates
Replace existing model views when true
Example

In This Topic
    CreateViewPlacements Method
    In This Topic
    Creates model views report
    Syntax
    public void CreateViewPlacements( 
       Project oProject,
       StringCollection colTemplates,
       bool bReplaceExisting
    )
    public:
    void CreateViewPlacements( 
       Project^ oProject,
       StringCollection^ colTemplates,
       bool bReplaceExisting
    ) 

    Parameters

    oProject
    Project
    colTemplates
    Collection of templates
    bReplaceExisting
    Replace existing model views when true
    Exceptions
    ExceptionDescription
    If any of parameters is null.
    If any of parameters is invalid.
    Failed to create. Please refer to the error message.
    An internal error occurred during creating. Please refer to the error message.
    Example
    //prepare page macro file for a report template
    System.IO.File.Copy(strMacrosDirectory + "\\ModelView.emp", new ProjectManager().Paths.Macros + "\\ModelView.emp", true);
    //load report template
    ProjectSettings oProjectSettings = new ProjectSettings(m_oProject);
    oProjectSettings.ReadSettings(strXMLDirectory + "\\ModelView.xml");
    StringCollection oTemplates = new StringCollection();
    oTemplates.Add("1");
    new Reports().CreateViewPlacements(m_oProject, oTemplates, true);
    See Also