Window.Handle

I’m using google translation to make it into English, so I’m sorry if it’s strange English.

so far
Var hWnd As Integer
hWnd = w.Handle
It was working as, but in API 2.0

Type mismatch error. Expected Integer, but got Ptr
hWnd = w.Handle

is displayed and the DataType seems to be Ptr.
I would like to convert the value of Ptr into an integer, how should I do this?

Change to:

hWnd = Integer(w.Handle)

to change from Ptr to Integer data type

I’m glad I didn’t have to do anything special.
I got the result I wanted.
thank you.