Jump to content
Tuts 4 You

How To Use Dr0,..,Dr7 In VB ?


Sh4DoVV

Recommended Posts

Posted

Hi Friends

How To Use Register Of Dr0,..,Dr7 In Visual Basic And Set Hardware BreakPoint ?

Thanks

Posted

Same as in any other language with SetThreadContext:

Declare Function SetThreadContext Lib "kernel32.dll" _
Alias "SetThreadContext" ( _
ByVal hThread As Long, _
lpContext As CONTEXT) As Long
Public Type CONTEXT86
ContextFlags As Long
Dr0 As Long
Dr1 As Long
Dr2 As Long
Dr3 As Long
Dr6 As Long
Dr7 As Long
FloatSave As FLOATING_SAVE_AREA
SegGs As Long
SegFs As Long
SegEs As Long
SegDs As Long
Edi As Long
Esi As Long
Ebx As Long
Edx As Long
Ecx As Long
Eax As Long
Ebp As Long
Eip As Long
SegCs As Long
EFlags As Long
Esp As Long
SegSs As Long
End Type
Posted

But do not use this API on a running thread (e.g. the current), suspend it first. Dependent on VB's way to process exception you could give modifying the CONTEXT pointer in an exception handler a try.

Posted

May Attach An Example That Used Of Dr0..Dr7 ?

Posted

May Attach An Example That Used Of Dr0..Dr7 ?

yes pls if that possible ..... :confused:

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...