My.Computer.FileSystem.SpecialDirectories.AllUsersApplicationData Property
Gets a path name pointing to the application's data in the \Documents and Setting\All Users\ApplicationData directory.
' Usage
Dim value As String = My.Computer.FileSystem.SpecialDirectories.AllUsersApplicationData
' Declaration
Public ReadOnly Property AllUsersApplicationData As String
String.
The following condition may cause an exception:
- The path is empty, usually because the operating system does not support the directory (DirectoryNotFoundException).
The My.Computer.FileSystem.SpecialDirectories Object contains paths to commonly referenced directories.
This example displays the path for the AllUsersApplicationData directory in a MessageBox.
MsgBox _
(My.Computer.FileSystem.SpecialDirectories.AllUsersApplicationData)
Namespace: Microsoft.VisualBasic.MyServices
Class: SpecialDirectoriesProxy (provides access to SpecialDirectories)
Assembly: Visual Basic Runtime Library (in Microsoft.VisualBasic.dll)
Project type | Available |
---|---|
Windows Application |
Yes |
Class Library |
Yes |
Console Application |
Yes |
Windows Control Library |
Yes |
Web Control Library |
Yes |
Windows Service |
Yes |
Web Site |
Yes |
The following permission may be necessary:
Permission | Description |
---|---|
Controls the ability to access files and folders. Associated enumeration: Unrestricted. |
For more information, see Code Access Security and Requesting Permissions.
My.Computer.FileSystem.SpecialDirectories Object
Microsoft.VisualBasic.FileIO.SpecialDirectories.AllUsersApplicationData