Win32Interop.GetWindowIdFromWindow(IntPtr) 方法
參考
定義
命名空間:Microsoft.UI
如果提供的 HWND
有效,則取得與指定 hwnd 對應的 WindowId
。
public static WindowId GetWindowIdFromWindow(IntPtr hwnd);
參數
hwnd
IntPtr
要取得 WindowId
視窗的處理常式
傳回
如果提供的 hwnd 有效,則與指定的 hwnd 對應的識別碼。 否則為 null
。
適用於
Products | 導入 |
---|---|
WinUI 3 | Windows App SDK 1.0 |
另請參閱
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應