Code: Alles auswählen
FUNCTION SetWindowLayered(hWnd,lActive)
hier aus diesem Forum Thema "transparente Fenster"
es geht also darum das man "irgendwie" M$ "Bausteine" in ihrer Optik
verändern kann, was bei Xbase++ nicht für ALLE XbParts gilt. Es
heisst dann nur "geht nicht weil M$ Windows" ...
so nun wieder VB Code
Code: Alles auswählen
Private Sub Form_Initialize()
Call InitCommonControls
Const WM_USER = &H400
Const GWL_STYLE = (-16)
Const PBM_SETMARQUEE = WM_USER + 10
mlSetStyle = GetWindowLong(ProgressBar1.hwnd, GWL_STYLE)
mlSetStyle = mlSetStyle Or PBM_SETMARQUEE
mlSetStyle = SetWindowLong(ProgressBar1.hwnd, GWL_STYLE, mlSetStyle)
End Sub
Private Sub Timer1_Timer()
ProgressBar1.Value = op
ProgressBar2.Value = op
op = op + 1
If op > ProgressBar1.Max Then op = 0
End Sub
Code: Alles auswählen
mlSetStyle = mlSetStyle Or PBM_SETMARQUEE
Code: Alles auswählen
hwndPB := oProgress:hWnd
mlSetStyle := GetWindowLongA(hwndPB, GWL_STYLE)
mlSetStyle := BOR(mlSetStyle, PBM_SETMARQUEE )
mlSetStyle := SetWindowLongA(hwndPB, GWL_STYLE, mlSetStyle)
ist das BOR() da richtig so ?
Code: Alles auswählen
SetWindowLong(hProgressBar, GWL_STYLE, GetWindowLong(hProgressBar, GWL_STYLE) OR PBS_MARQUEE)
...
also der nächste Google Treffer :
Code: Alles auswählen
hi got it working :)
Modified the code
// done at the top of the file
#define PBS_MARQUEE 0x08
#define PBM_SETMARQUEE WM_USER + 10
SetWindowLongPtr(hProgressBar,GWL_STYLE,PBS_MARQUEE);
SendMessage(hProgressBar,(UINT) PBM_SETMARQUEE,(WPARAM) TRUE,(LPARAM)50 );
Code: Alles auswählen
LONG_PTR SetWindowLongPtr(
HWND hWnd,
int nIndex,
LONG_PTR dwNewLong
);
Xbase++
DLLFUNCTION SetWindowLongPtr(nHWnd,nIndex,dwNewLong) USING STDCALL FROM USER32.DLL
...
Stunden später :
äh, em ... und ich habe die ganze Zeit unter XP auf die 5.82 gearbeitet ...Send the PBM_SETMARQUEE message to start or stop the animation.
Note You must set the control style to PBS_MARQUEE before attempting to start the animation.
Note This message requires ComCtl32.dll version 6.00 or later.
also noch mal die Brüllkiste mit VISTA anschalten und die Sample auf dem VISTA PC probieren.
...
ne das bringt es auch nicht. Kein Unterschied unter VISTA und kein Effekt ...
sobald ich
Code: Alles auswählen
SetWindowLongA(hwndPB, GWL_STYLE, PBS_*** )
An der Stelle hab ich nun vorgestern Nacht frustriert aufgegeben ... unwissend das ich kurz vor
dem Ziel war ...
Ende Teil 2
Fortsetzung folgt