can anybody help me?
I want to create a usercontrol in VB6 which should behave like a normal
I tried to put the textBox onto the usercontrol and wrote the needed events
and properties but the propertie for multiline can't be set at runtime!
So i decided to create an own usercontrol with edit-capabilities.
Now my problem:
I started to create an edit-class like this:
StdStyles = WS_CHILD Or WS_VISIBLE Or ES_LEFT Or ES_AUTOHSCROLL Or
ES_WANTRETURN Or ES_MULTILINE
TextBoxWnd = CreateWindowEx(ExStyles, "Edit", "Text1", StdStyles, 0, 0,
ScaleWidth, ScaleHeight, UserControl.hwnd, 0&, App.hInstance, 0&)
Now how can I change the backgroundcolor of my edit-class window?
I tried with
SetBKColor-Api or subclassed the WM_PAINT event but nothing works, the
backcolor is always standard-windows colored
idc = GetWindowDC(TextBoxWnd)
Debug.Print "bk" & SetBkColor(idc, vbWindowText)
Debug.Print "tk" & SetTextColor(idc, RGB(128, 128, 128))
ReleaseDC TextBoxWnd, idc
Now what to do? Any Ideas?
Thanks for your help