Muokkaa

Jaa


Explorer.CurrentFolder property (Outlook)

Returns or sets a Folder object that represents the current folder displayed in the explorer. Read/write.

Syntax

expression. CurrentFolder

expression A variable that represents an Explorer object.

Remarks

Use this property to change the folder the user is viewing.

Example

This Visual Basic for Applications (VBA) example uses the CurrentFolder property to change the displayed folder to the user's Calendar folder.

Sub ChangeCurrentFolder() 
 
 Dim myNamespace As Outlook.NameSpace 
 
 
 
 Set myNamespace = Application.GetNamespace("MAPI") 
 
 Set Application.ActiveExplorer.CurrentFolder = _ 
 
 myNamespace.GetDefaultFolder(olFolderCalendar) 
 
End Sub

See also

Explorer Object

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.