Share via


IXRWin32Control::SetClassName (Compact 2013)

3/28/2014

This method sets the name of the class that this IXRWin32Control object belongs to.

Syntax

virtual HRESULT STDMETHODCALLTYPE SetClassName (
    const WCHAR* pClassName
) = 0; 

Parameters

  • pClassName
    [in] Pointer to a string that contains the class name.

Return Value

Returns an HRESULT that indicates success or failure. If a window handle already exists, returns E_UNEXPECTED.

Remarks

The value in pClassName corresponds to the lpClassName parameter of CreateWindow or CreateWindowEx. You can use CreateWindow or CreateWindowEx to create the window control before you set its handle to the handle of the IXRWin32Control object and insert it into the visual tree.

SetClassName only works if it is called before the window handle is created. If you call SetClassName after the window handle is created, it returns E_UNEXPECTED.

.NET Framework Equivalent

None.

Requirements

Header

XamlRuntime.h

sysgen

SYSGEN_XAML_RUNTIME

See Also

Reference

IXRWin32Control
IXRWin32Control::GetClassName