createView (Database - Java)

Creates a view.

Note: This method is new with Release 6.5.

Defined in

Database

Syntax

public View createView()
    throws NotesException
public View createView(String viewname)
    throws NotesException
public View createView(String viewname, String viewselectionformula)
    throws NotesException
public View createView(String viewname, String viewselectionformula, View templateview)
    throws NotesException
public View createView(String viewname, String viewselectionformula, View templateview, boolean prohibitdesignrefreshmodifications)
    throws NotesException

Parameters

String viewname

A name for the view. Defaults to the "(untitled)" view. The view is created even if this name duplicates an existing view.

String viewselectionformula

A selection formula. Defaults to either:

  • selection formula of the template view
  • "SELECT @All" if no template view exists

If specified, this formula overrides the selection formula of the template view.

View templateview

An existing view from which the new view is copied. Defaults to either:

  • view checked as "Default design for new folders and views" in the database
  • none if no view in the database is specified as the default design
Note: The template view can not be of type Shared, desktop private on first use.

boolean prohibitdesignrefreshmodifications
  • true (default) to prohibit the view design from being refreshed
  • false to allow the view design to be refreshed

Return value

View

The new view.

Usage

If no template view exists, the new view contains one column with "@DocNumber" as its value. The template view must be accessible to the program, so can be a public view or a private view owned by the effective id running the agent, but can not be a private view stored in the desktop.

Example