Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

CngKey::ParentWindowHandle Property

 

Gets or sets the window handle (HWND) that should be used for user interface (UI) prompts caused by accessing the key.

Namespace:   System.Security.Cryptography
Assembly:  System.Core (in System.Core.dll)

public:
property IntPtr ParentWindowHandle {
	IntPtr get();
	[SecurityPermissionAttribute(SecurityAction::Demand, UnmanagedCode = true)]
	void set(IntPtr value);
}

Property Value

Type: System::IntPtr

The parent window handle for the key.

The parent window handle for the key is used in UI prompts, such as smart card PIN prompts. This value is not persisted with persisted keys.

We recommend that you always set this property for keys that display a user interface. Do not use the default value of null for such keys.

SecurityPermission

for permission to call unmanaged code. Demand value: LinkDemand. Associated enumeration: SecurityPermissionFlag::UnmanagedCode

.NET Framework
Available since 3.5
Return to top
Show:
© 2017 Microsoft