ctjh900801
Member
- Joined
- Aug 30, 2011
- Messages
- 5
- Programming Experience
- Beginner
API Declarations
<DllImport("oleacc.dll")> _
Shared Function ObjectFromLresult (ByVal lResult As IntPtr, <MarshalAs(UnmanagedType.LPStruct)> ByVal refiid As Guid, ByVal wParam As IntPtr) As <MarshalAs(UnmanagedType.Interface)> Object
End Function
Private Function WDom (ByVal hWnd As IntPtr) As mshtml.IHTMLDocument
Dim L As IntPtr, M As Long
Dim IHTMLDocumentIDAsString As New Guid ("626FC520-A41E-11CF-A731-00A0C9082637")
M = RegisterWindowMessage ("WM_HTML_GETOBJECT")
If M <> 0 Then
SendMessageTimeout (hWnd, M, 0L, 0L, SMTO_ABORTIFHUNG, 1000L, L)
If L <> 0 Then
Return DirectCast (ObjectFromLresult (L, IHTMLDocumentIDAsString, 0), mshtml.IHTMLDocument) <<<'attempt to read or write protected memory. This usually means that other memory is corrupt.
End If
End If
End Function
When I go to extract the GUID with ObjectFromLresultAccessviolationException not occurred at the
Management 'attempt to read or write protected memory. This usually means that other memory is corrupt.
What does the way in here to deal with ObjectFromLresult the API to be successful extraction GUID.
<DllImport("oleacc.dll")> _
Shared Function ObjectFromLresult (ByVal lResult As IntPtr, <MarshalAs(UnmanagedType.LPStruct)> ByVal refiid As Guid, ByVal wParam As IntPtr) As <MarshalAs(UnmanagedType.Interface)> Object
End Function
Private Function WDom (ByVal hWnd As IntPtr) As mshtml.IHTMLDocument
Dim L As IntPtr, M As Long
Dim IHTMLDocumentIDAsString As New Guid ("626FC520-A41E-11CF-A731-00A0C9082637")
M = RegisterWindowMessage ("WM_HTML_GETOBJECT")
If M <> 0 Then
SendMessageTimeout (hWnd, M, 0L, 0L, SMTO_ABORTIFHUNG, 1000L, L)
If L <> 0 Then
Return DirectCast (ObjectFromLresult (L, IHTMLDocumentIDAsString, 0), mshtml.IHTMLDocument) <<<'attempt to read or write protected memory. This usually means that other memory is corrupt.
End If
End If
End Function
When I go to extract the GUID with ObjectFromLresultAccessviolationException not occurred at the
Management 'attempt to read or write protected memory. This usually means that other memory is corrupt.
What does the way in here to deal with ObjectFromLresult the API to be successful extraction GUID.