Table of contents
TOC
Collapse the table of content
Expand the table of content

Application.VisualReportsView Method (Project)

office 365 dev account|Last Updated: 6/12/2017
|
1 Contributor

Opens the specified Visual Reports template with the specified level of time.

Syntax

expression. VisualReportsView( ** strVisualReportTemplateFile, ** PjVisualReportsDataLevel )

expression A variable that represents an Application object.

Parameters

NameRequired/OptionalData TypeDescription
strVisualReportTemplateFileOptionalStringFull path and name of template file.
PjVisualReportsDataLevelOptionalLongThe time level of data, determined automatically or specified from days to years . Can be one of the PjVisualReportsDataLevel constants. The default value is pjLevelAutomatic.

Return Value

Boolean

Remarks

The PjVisualReportsDataLevel parameter specifies the level to which the timephased data can be accessed. For example, if pjLevelMonths (months) is specified, it not possible to access pjLevelDays (days).

Opening the template with a time level that is not supported by the data results in an error.

Example

The following example opens the "PCRTSK_U.VST" template for viewing.

Sub a() 
 Dim tf As Boolean 
 tf = Application.VisualReportsView("D:\Program Files\Microsoft Office\Office12\1033\PCRTSK_U.VST", pjLevelAutomatic) 
 If tf = True Then 
 MsgBox ("Template was viewed successfully") 
 Else 
 MsgBox ("Template was not viewed successfully") 
 End If 
End Sub
© 2018 Microsoft