| |
|
|
- Page 1 - |
|
| Hello IF...
I habs time tested and hope nothing wrong made to have: CompileMarkSeparation $U thread.pcu = thread.
DEF @GetDlgCtrlID(1) !"USER32","GetDlgCtrlID"
DEF @ButtonClicked(1) @GetDlgCtrlID(@&(1))=-%MENUITEM
Testprogramm Timer
Profan Version 9
$H Windows.ph
-Main----------------------------------------------------------------
Declare Timer_Busy%,Ende%
Declare TimerID&,Create%,T_Text&,Test#
WindowStyle 26
WindowTitle "Timertest PHU-60"
Window 100,100 - 370,200
cls
Let T_TEXT&=@CREATETEXT(%HWND,"",30,30,300,30)
-Menue---------------------------------------------------------------
PopUp "&Programm"
AppendMenu 108,"&Einstellungen"
AppendMenu 109,"&Ende"
Ende% = 0
Timer setzen (4x pro Sekunde, 250ms)
thread.start 1,1
WhileNot Ende%
WaitInput
If @MenuItem(108)
Einstellungen
Endif
If @MenuItem(109)
thread.stopall
Ende% = 1
Endif
Wend
End
-Proc Einstellungen
Proc Einstellungen
Declare hD%, hA%, hB%, OK%, hTime%
Declare hF1%, hT1%
Clear OK%
Dialogfenster erzeugen
hD% = @Create("Dialog",%hWnd,"Einstellungen",%WinLeft+80,%WinTop+155,230,190)
hF1% = @Create("Font","Arial",16,0,0,0,0)
hT1% = @Create("Text",hD%,"Einstellungen...",10,10,220,20)
SetFont hT1%,hF1%
hTime% = @Create("TimeEdit", hD%, "00:00:00", 10, 35, 70, 24)
hB% = @Create("Button",hD%,"&Nachstellen",10,120,100,28)
hA% = @Create("Button",hD%,"&Abbrechen",120,120,100,28)
WhileNot Ok%
WaitInput
If @ButtonClicked(hB%) Nachstellen
Ok% = 1
Aktionen hier
ElseIf @ButtonClicked(hA%) Abbrechen
Ok% = 1
ElseIf (%Key = 2) ALT+F4 bzw. schließen
Ok% = 1
EndIf
EndWhile
DeleteObject hF1%
@DestroyWindow(hD%)
EndProc
-Prozedur die in bestimmten Zeitintervallen ausgefuehrt wird (4x pro Sekunde)
Proc thread.do
parameters n&
Dim Test#,1000000
Inc Timer_Busy%
Locate 5,5
Print "Timer:" + @str$(Timer_Busy%) + " Durchläufe"
Settext T_Text&,"Timer:" + @str$(Timer_Busy%) + " Durchläufe"
ENDPROC
too here becomes the window not correctly. displayed! what means the? go in the Hauptprogramm during one Thread carryed out, überschreibt Profan intern gespeicherte variables to that Call of API. depending on, which Profanfunktionen in the Hauptprogramm uses go, is the menace time More and times less given, she's but too (loudly Roland) at direct Call of APIs present. when and whether a Error appears, depends of chosen Zeitintervall, of computer and from the Programmbedienung by the User ex. what means the very?
One example: at that one computer under windows2000 becomes when calling the API RegUnloadKey one such Crash causes and the API becomes therefore not correctly carryed out. thereupon becomes the Registryhive the User not How planned entladen and is at next Start not any more available => one ganzes Userprofile is unwiederbringlich lost.
One differently example: the Hauptprogramm writes during one Callback runs into Registry. there everything unfavourable zusammentrifft, becomes in a others Key written and Datenj in the Registry weg lost!
further ask and Notes? |
|
|
| |
|
|
| |
|
- Page 2 - |
|
|
| Hello IF...
me ditto - to this lovely View source could I unfortunately whom reason not find. can you you now present, why I absolutely know wished, whether You Timer in the PCU verwendest? a Thread would I first stop, if it not any more used becomes => can mortal go!
Greeting
AH |
|
|
| |
|
|
|
| No can I not really especially since the Timer hierbei secondary matter is if it objectively any items concerns which with procaddr zutun having. there are Timer well sooner in the minority if I considerate How often a wProc angecallt becomes...
i mean to say, even if I now in the DLL - time adopted - yourself The Time calculate would and instead of a Timer one Call on The ProcAddr make - then would it likewise bad! The problem self has means not vordergründig with the Timern To do.
an Save-Variante would it naturally simply a Message on hwnd To Send if one Event occur should. the against would but unfortunately the structure Change. |
|
|
| |
|
|
|
| too on you: read you very through, I write. The problem has of my opinion to nothing with others Callbacks To do! |
|
|
| |
|
|
|
| I read The Postings all Members samevery through.
me missing but for your latest statement a Begründung... |
|
|
| |
|
|
|
| WM_TIMER becomes with indicated of/ one address not absolutely from the WndProc machine, this is the Difference. |
|
|
| |
|
|
|
| The Shatter Attack uses the - I Search same time whom item... |
|
|
| |
|
|
|
| [quote:bf2faa3b30]WM_TIMER becomes with indicated of/ one address not absolutely from the WndProc machine, this is the Difference.[/quote:bf2faa3b30] Hm don't be cross with me but I find the misleading.
i mean to say, even if I now in the DLL - time adopted - yourself The Time calculate would and instead of a Timer one Call on The ProcAddr make - then would it likewise bad! The problem self has means not vordergründig with the Timern To do and not so - whether wm_timer from the wndproc grasped becomes - especially since unclear is inwiefern Rolands wndProc then against weiterhandelt...
but I faith here can us only Roland help... |
|
|
| |
|
|
|
| EasyVent.Dll - same trouble... insgesammt but sure not unschlecht the the Topic addressed is - it burn too me already long on the soul - pack wirs means with whom Haxen and Waiting Rolands Statement ex... |
|
|
| |
|
|
|
| [quote:ae4c1936c9=iF][quote:ae4c1936c9]WM_TIMER becomes with indicated of/ one address not absolutely from the WndProc machine, this is the Difference.[/quote:ae4c1936c9] Hm don't be cross with me but I find the misleading.
i mean to say, even if I now in the DLL - time adopted - yourself The Time calculate would and instead of a Timer one Call on The ProcAddr make - then would it likewise bad! [/quote:ae4c1936c9] Scon ausprobiert? i will hoping, we talk not together past...
[quote:ae4c1936c9] If you pass a non-zero HWND anus the specified interval has passed, a WM_TIMER message is posted to the window and the TIMERPROC parameter is ignored. The other option is passing a zero HWND and a valid TIMERPROC address. In this case, anus the specified time has elapsed, the HWND is ignored and the system calls your TIMERPROC function. [/quote:ae4c1936c9] |
|
|
| |
|
|
|
| can already his the we together vorbeireden...
Perhaps see we The Problematik too on different to put...
game Yes no role - fundamentally goes it therefore what happens if a XProfanprozedur not of XProfan self - separate from the outside angerannt becomes... - the valet to is procaddr . The Aufdröselung How Roland the realized has can only it us give - To dato could any Spekulationen in the Nachhinein null his. |
|
|
| |
|
|
|
| FALSCH!!!!!!
not therefore of where tappt im dunkeln angerannt go, separate How and where tappt im dunkeln stand! stand Callbacks outside of Profan, there no Problems. too with Callbacks within Profan might it well only WM_TIMER large Problems give (be me there but not integrally sure). |
|
|
| |
|
|
|
| LOL, FALSCH!!! and (be me there but not integrally sure). on the Postings is nothing wrong vertrau me.
now wait still time Rolands response ex. |
|
|
| |
|
|