|
-
Nov 11th, 2003, 11:05 PM
#1
Hdc *resolved*
Why is it that the Form1 has an .HDC property, and the controls on my form don't? I'm trying to pass a control to the DrawText API, but it requires a control's .hdc property passed as an argument, which my control doesn't have.
What can I do instead?
Last edited by mendhak; Nov 11th, 2003 at 11:15 PM.
-
Nov 11th, 2003, 11:05 PM
#2
Here's the API, btw
VB Code:
Private Declare Function DrawText Lib "user32" Alias "DrawTextA" _
(ByVal hdc As Long, ByVal lpStr As String, ByVal nCount As Long, _
lpRect As RECT, ByVal wFormat As Long) As Long
-
Nov 11th, 2003, 11:09 PM
#3
If the control has an hWnd, you can use the GetDC API.
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Nov 11th, 2003, 11:15 PM
#4
-
Nov 11th, 2003, 11:16 PM
#5
Boy, if I had a bagel for everytime I heard that...
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|