English
Forum

where is my Error ?

 

diimool25

CompileMarkSeparation
pfad$ = "J:\1"+".txt"

if fileexists(pfad$)

    clearlist
    assign #1, Pfad$
    reset #1

    WhileNot @Eof(#1)

        i% = i%+1
        Input #1,Zeile$
        SetText RadionButton%[i%], Zeile$

    EndWhile

    close #2>1

wieso catches it in the Program on whom 1. from the txtdatei at 6. button To make ?
 
03/07/14  
 




Jörg
Sellmeyer
One aray is nullbasierend. You setting but whom index i% same on 1. therefore becomes the second Arrayfeld quizzed.
CompileMarkSeparation
Declare Arr%[9]
Cls

WhileLoop 0,9

    Arr%[&Loop] = &Loop

Wend

WhileLoop 0,9

    Print Arr%[&Loop]

Wend

CompileMarkSeparation
way$ = "J:\1"+".txt"
with the + and not
CompileMarkSeparation
way$ = "J:\1.txt"
 
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
03/07/14  
 




diimool25
had I made there with the the 1 Yes only ne Test File is what about me having the elsewhere Schonmal so made and because I had the so übernommen but thanks
 
03/07/14  
 




diimool25
undwas should I now very take away ?
 
03/07/14  
 




diimool25
Ahh I have my Error already found I had i% already before it used and there was i% already on 6 desswegen has it egg 6 started
 
03/07/14  
 




diimool25
wieso can I no buttons with the countdown benefit ?
proc count2

Set("Decimals",1)
var time%=&GetTickCount
var text&=Create("Text",%hwnd,"",30,30,120,20)

while &GetTickCount-time%<60000
Case &GetTickCount-time%<60000 : Settext text&,Str$((60000-(&GetTickCount-time%))/1000) + " Sekunden"
Endwhile

Endproc
 
03/08/14  
 




H.Brill
i'd time with Rechenoperationen clinging using.
CompileMarkSeparation
Set("Decimals",1)
Cls
var time%=&GetTickCount
var text&=Create("Text",%hwnd,"",30,30,120,20)

while (&GetTickCount-time%) < 60000

    Case (&GetTickCount-time%) < 60000 : Settext text&,Str$((60000-(&GetTickCount-time%))/1000) + " Sekunden"

End
/a>

is in the first, rather To reading and secondly comes XProfan
too then not confusion.

in the obigen code see I of course no Erzeugung of Buttons, but I take
on, that You the in your Gesamtcode make.

If you whom above-mentioned Proc count2 ausführst, becomes in this 60 sec
too nothing more weg, because the While-Loop so beschäftig is,
with SetText.... a Text To settle. here best SetTimer using
and the not too small make, sodaß WaitInput in your Hauptschleife
too yet react can.

The better lane is, MultiProzessing To use. there is in the
Help z.B. described, How one The Time in the Titelleiste indicating.

the could z.B. so looks :
CompileMarkSeparation
Declare start&, stop&, liste&, ende&, end2&, pid&
Window Style 16' system-Menu Hide
Window Title "Haupt - Fenster"
Window 600,  500
start& = @Create("Button", %HWnd, "Start", 10, 10, 80, 25)
stop&  = @Create("Button", %HWnd, "Stop",  100,10, 80, 25)
ende&  = @Create("Button", %HWnd, "Ende",  190,10, 80, 25)
liste& = @Create("Listbox", %HWnd, 0, 10, 50, 400, 200)
ende2& = 0
EnableWindow stop&, 0

WhileNot end2&

    WaitInput

    If @Clicked(start&)

        ClearList liste&
        pid& = pExec("|Count2", %HWnd, liste&)

        If pid& > 0

            EnableWindow stop&, 1
            EnableWindow start&, 0

        EndIf

    ElseIf @Clicked(stop&)

        If pid& > 0

            Process("Kill", pid&, 0)
            EnableWindow start&, 1
            EnableWindow stop&, 0

        EndIf

    ElseIf @Clicked(ende&)

        If pid& > 0

            Process("Kill", pid&, 0)

        EndIf

        end2& = 1

    EndIf

EndWhile

Proc Count2

    Parameters whandle&, listb&
    Set("Decimals",1)
    var end1% = 0
    var time%=&GetTickCount
    var text&=Create("Text",%hwnd,"",30,30,120,20)

    While ((&GetTickCount-time%) < 60000) OR (end1% = 1)

        Case getText$(whandle&) = "" : end1% = 1

        If (&GetTickCount-time%) < 60000

            AddStrings(listb&, Str $((60000-(&GetTickCount-time%))/1000) + " Sekunden")
            SendMessage(listb&, $0186, @GetCount(listb&) -1, 0)

        EndIf

    Endwhile

ENDPROC

End
 
Benutze XPROFAN X3 + FREEPROFAN
Wir sind die XProfaner.
Sie werden von uns assimiliert.
Widerstand ist zwecklos!
Wir werden alle ihre Funktionen und Algorithmen den unseren hinzufügen.

Was die Borg können, können wir schon lange.
03/08/14  
 



Answer


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

7.135 Views

Untitledvor 0 min.
Jochen Roxlau04/14/15
Heinz Bernhard11/29/14
Georg Teles09/04/14
iF07/09/14
More...

Themeninformationen



Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie