| |
|
|
Ralph Theobald | Hello ,
I have a GridBOX in a Choicebox gebastelt , unfortunately is the GridBOX Not Available, how can I these enable. CompileMarkSeparationSet(FastMode,1)
$H windows.ph
$H messages.ph
Declare oldcallback&,static&,brush&,raus&,hGrid&,titel$
cls
oldcallback&=~SetWindowLong(%hwnd,~GWL_WNDPROC,ProcAddr(newcallback,4))
static&=Create(choicebox,%hwnd,Choicebox,16,16,560,180)
WhileNot raus&
WaitInput
EndWhile
End
PROC setcolor
Parameters col&,bk&,wParam&
declare Brush&
IF Brush&
~DeleteObject(Brush&)
endif
Brush& = ~CreateSolidBrush(bk&)
~SetBkMode(wParam&, ~TRANSPARENT)
~SetBKColor(wParam&,RGB(195,116,95))
~SetTextColor(wParam&,col&)
RETURN Brush&
endproc
Proc newcallback
Parameters wnd&,msg&,wparam&,lparam&
IF msg&=~WM_CTLCOLOREDIT
RETURN SetColor(rgb(255,0,0),rgb(255,255,0),wParam&)
Endif
IF msg&=~WM_CTLCOLORLISTBOX
Titel$ = Links;0;80;Mitte;2;100;Rechts;1;80
hGrid&=Create(GridBox,lparam&, Titel$, 3,1,1,549,140)
AddString(hGrid&, AB|DEF|0123)
AddString(hGrid&, GHI|J23KL|012345)
IF brush&
~DeleteObject(brush&)
EndIf
brush&=~CreateSolidBrush(Rgb(0,0,255))
RETURN brush&
Endif
If msg&=~WM_CLOSE
~DeleteObject(brush&)
raus&=1
Endif
RETURN ~CallWindowProc(oldcallback&,wnd&,msg&,wparam&,lparam&)
s4 href='./../../Function-References/XProfan/endproc/'>ENDPROC
Greeting Ralph |
|
|
| |
|
|
|
| at that Click on The Choicebox sustain I unfortunately only a crash. |
|
|
| |
|
|
|
Jörg Sellmeyer | iF
at that Click on The Choicebox sustain I unfortunately only a crash.
interestingly - not at me. I can but too the List view not anwählen. sees anyway integrally jolly from. though is it fraglich, whether it in the form irgendeinen benefit bring. you mußt Yes the control jedesmal new create. with umfangreichem Content might the quite break. More falls me moreover unfortunately not one, there this whole Callback-Zeugs me always headaches bereitet. Greeting Jörg |
|
|
| Windows XP SP2 XProfan X4... und hier mal was ganz anderes als Profan ... | 03/08/07 ▲ |
|
|
|
|
| Jupp - Callbacks in XProfan are unfortunately because of which the ProcAddr yet ungestackt operates not recommendable and go accordingly always Problems bound. Perhaps Gibts in X11 remedy. |
|
|
| |
|
|
|
Ralph Theobald | thanks you both,
XProfan 10 has one Control (Dateedit) with the functions the Focus on the Calendar. Perhaps is correct The Message in the Callbackroutine not . Werd time another little testing.
Greeting Ralph |
|
|
| |
|
|
|
| I Have ne Solution - integrally without Fastmode and Procaddr.
only another small coolness to fix... |
|
|
| |
|
|
|
| sees from as though: CompileMarkSeparation {$cleq}
cls
long static=Create(choicebox,%hwnd,Choicebox,16,16,560,180)
usermessages 16,WM_CTLCOLORLISTBOX
do {
waitinput
select umessage
caseof 16 : break
caseof WM_CTLCOLORLISTBOX : proceedChoiceBox
caseof WM_CTLCOLOREDIT : break
otherwise
endselect
}
end
proceedChoiceBox {
string Titel:=Links;0;80;Mitte;2;100;Rechts;1;80
long parent=FindWindowExA(65556,0,ComboLBox,0)
showwindow(parent,0)
long hGrid=Create(GridBox,hwnd, Titel, 3,16,40,width(parent),height(parent))
sendkey(parent,27)
addString(hGrid,AB|DEF|0123)
addString(hGrid,GHI|J23KL|012345)
while getAsyncKeyState(1)<>0
wend
dulcoiF
waitinput
case getfocus(static) : sendkey(parent,27)
string s
if getCurSel(hGrid)>-1
s:=getstring$(hGrid,getCurSel(hGrid))
endif
destroywindow(hGrid)
ifnot s== {
locate 10,1
print Ausgewählt: ,s
}
}
dulcoiF { settimer 1;waitinput;killtimer }
The Nichtxpsevariante: CompileMarkSeparationDECLARE __cf1&,__cf2&
Def __cf1(2) !KERNEL32,GetProcAddress
Def __cf2(1) !KERNEL32,GetModuleHandleA
__cf1&=__cf1(__cf2(user32.dll),FindWindowExA)
__cf2&=__cf1(__cf2(user32.dll),GetAsyncKeyState)
CLS
var STATIC&=CREATE(choicebox,%HWND,Choicebox,16,16,560,180)
USERMESSAGES 16,$0134
WHILE 1
WAITINPUT
SELECT %UMESSAGE
CASEOF 16
BREAK
CASEOF $0134
PROCEEDCHOICEBOX
OTHERWISE
ENDSELECT
ENDWHILE
end
proc PROCEEDCHOICEBOX
var TITEL$=left;0;80;middle;2;100;right;1;80
var PARENT&=call(__cf1&,65556,0,ComboLBox,0)
SHOWWINDOW(PARENT&,0)
var HGRID&=CREATE(GridBOX,%HWND, TITEL$, 3,16,40,WIDTH(PARENT&),HEIGHT(PARENT&))
SENDKEY(PARENT&,27)
ADDSTRING(HGRID&,AB|DEF|0123)
ADDSTRING(HGRID&,GHI|J23KL|012345)
WHILE call(__cf2&,1)<>0
ENDWHILE
DULCOIF
WAITINPUT
IF GETFOCUS(STATIC&)
SENDKEY(PARENT&,27)
ENDIF
var s$=
IF GETCURSEL(HGRID&)>-1
s$=GETSTRING$(HGRID&,GETCURSEL(HGRID&))
ENDIF
DESTROYWINDOW(HGRID&)
IFNOT s$=
LOCATE 10,1
PRINT select: ,s$
ENDIF
endproc
proc DULCOIF
SETTIMER 1
WAITINPUT
KILLTIMER
endproc
|
|
|
| |
|
|
|
| i'd from it warscheinlich a class building around the Control with one individual appeal To to check on and several of it create to - but the remaining then you give over. |
|
|
| |
|
|
|
| Hello IF...
have by me under windows98 The EXE time tested - runs not. The Choicebox works immediate again To and its only one Farbengewirr To see. |
|
|
| |
|
|
|
| Schade with Win98, habs naturally for windows-XP written and tested. |
|
|
| |
|
|
|
| iF
Schade with Win98, habs naturally for windows-XP written and tested.
or evtl. only for your computer or for a defined Version the comctl32.dll? |
|
|
| |
|
|
|
| On one XPHome and a XPPro - both Uptodate. |
|
|
| |
|
|