Dynamicweb 8 Documentation
Current Method
Example 

Gets the PageView object of the current pageview. This can only be called in a frontend context.
Syntax
'Declaration
 
Public Shared Function Current() As PageView
public static PageView Current()

Return Value

Returns null or nothing if not called from frontend or prior to Pageview.Load event has occured
Remarks
Should only be called from code executed in frontend. Use PageView.GetPageviewByPageID from backend code.
Example
How to access the pageview instance
//Get current instance
 PageView pv = PageView.Current();
 //Change properties on the PageView object
 pv.Meta.Title = "New title";
How to access the pageview instance
'Get current instance
 Dim pv As PageView = PageView.Current
 'Change properties on the PageView object
 pv.Meta.Title = "New title"
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

PageView Class
PageView Members

Send Feedback