B Baris Karadeniz Active Member Licensed User May 14, 2016 #1 I want to use timer for http job. For example I will set it to 5 seconds and http job will be done every 5 seconds if I enable timer. If I disable timer http job will stop. How can I do this? Code: Copy Dim Job1 As HttpJob Job1.Initialize("MyJob", Me) Job1.Download2("http://www.xxx.com/yyy.php", Array As String("x", "y")) Sub JobDone (Job As HttpJob) Log("Job completed: " & Job.Success) Job.Release End Sub
I want to use timer for http job. For example I will set it to 5 seconds and http job will be done every 5 seconds if I enable timer. If I disable timer http job will stop. How can I do this? Code: Copy Dim Job1 As HttpJob Job1.Initialize("MyJob", Me) Job1.Download2("http://www.xxx.com/yyy.php", Array As String("x", "y")) Sub JobDone (Job As HttpJob) Log("Job completed: " & Job.Success) Job.Release End Sub
DonManfred Expert Licensed User Longtime User May 14, 2016 #2 Code: Copy sub timer_tick Dim Job1 As HttpJob Job1.Initialize("MyJob", Me) Job1.Download2("http://www.xxx.com/yyy.php", Array As String("x", "y")) end sub Upvote 0
Code: Copy sub timer_tick Dim Job1 As HttpJob Job1.Initialize("MyJob", Me) Job1.Download2("http://www.xxx.com/yyy.php", Array As String("x", "y")) end sub
B Baris Karadeniz Active Member Licensed User May 14, 2016 #3 How can I set the timer interval and how can I enable and disable? Upvote 0
DonManfred Expert Licensed User Longtime User May 14, 2016 #4 Baris Karadeniz said: How can I set the timer interval and how can I enable and disable? Click to expand... RTFM! * * Read the fucking manual Upvote 0
Baris Karadeniz said: How can I set the timer interval and how can I enable and disable? Click to expand... RTFM! * * Read the fucking manual
B Baris Karadeniz Active Member Licensed User May 14, 2016 #5 DonManfred you don't have to answer my questions. Upvote 0
DonManfred Expert Licensed User Longtime User May 14, 2016 #6 Even not if it is the solution? I provided a link to the documentation! There you can see a codesnippet and a description how to work with timer. If this dont help you.... But OK, don´t expect me to want to help you anymore. Upvote 0
Even not if it is the solution? I provided a link to the documentation! There you can see a codesnippet and a description how to work with timer. If this dont help you.... But OK, don´t expect me to want to help you anymore.
B Baris Karadeniz Active Member Licensed User May 14, 2016 #7 I said this because you don't speak politely (fucking). Upvote 0
DonManfred Expert Licensed User Longtime User May 14, 2016 #8 https://en.wikipedia.org/wiki/RTFM Upvote 0
B Baris Karadeniz Active Member Licensed User May 14, 2016 #9 I searched in the forums. I also searched beginners guide v1.1. But I couldn't see. Can not be? Upvote 0
tufanv Expert Licensed User Longtime User May 14, 2016 #10 When you type timer1. And click on initialize for example you can see the example. While initializing you must set the interval. Later you can changw it via timer1.interval = 1000 1000means 1 second. You must set 5000 for 5 seconds. Later under sub timer1_tick tou can type what you want. Tou can use b4x object browser to help yourself or use the beginners guide as donmanfred suggested Upvote 0
When you type timer1. And click on initialize for example you can see the example. While initializing you must set the interval. Later you can changw it via timer1.interval = 1000 1000means 1 second. You must set 5000 for 5 seconds. Later under sub timer1_tick tou can type what you want. Tou can use b4x object browser to help yourself or use the beginners guide as donmanfred suggested
B Baris Karadeniz Active Member Licensed User May 14, 2016 #11 Thanks tufanv. I searched the beginners guide again and I saw. I think I did something wrong when I searched the beginners guide first time. Upvote 0
Thanks tufanv. I searched the beginners guide again and I saw. I think I did something wrong when I searched the beginners guide first time.
B Baris Karadeniz Active Member Licensed User May 14, 2016 #12 Anyway, thanks DonManfred too. Upvote 0