gruss-software.co.uk Forum Index The Ultimate Betting Exchange Software
gruss-software.co.uk
FAQ  FAQ   Search  Search   Memberlist  Memberlist   Usergroups  Usergroups
Register  ::  Log in Log in to check your private messages


Post new topic  Reply to topic
 Q2 -1 triggering some problems, one event jump over .. « View previous topic :: View next topic » 
Author Message
jossari
PostPosted: Sun May 20, 2012 8:12 am    Post subject: Q2 -1 triggering some problems, one event jump over .. Reply with quote



Joined: 02 Oct 2008
Posts: 19

Hi,

I am using following code to jump next event:
- if market is closed (CELL F2) or if cell value AS18 = 1 (= "my own calculated cell in certain criterias")

The Cell value AS18 will check some other items from next event and if they are TRUE cell AS18 value will be 1 and then I will want to jump next event.

The problem is now, that this code will jump to next race too fast. I mean althoung next event and its cell value AS18 = 0, this code will jump over this event to the next event. This mean that one event will be missed ..

Is there any possibilities, that program will wait so long that cell value AS18 is certainly updated before program will jump out from if-loop?

BR: AH


If Target.Columns.Count = 16 Then
Application.EnableEvents = False

If Range("A1").Value <> NYKYMARKKINA Then marketMUUTTUNUT = False
If Range("F2").Value = "Closed" Or Range("AS18").Value = 1 Then
If Not marketMUUTTUNUT Then

Range("Q2").Value = -1
marketMUUTTUNUT = True

End If

.....
Back to top
View user's profile Send private message
alrodopial
PostPosted: Sun May 20, 2012 8:51 am    Post subject: Reply with quote



Joined: 06 Dec 2006
Posts: 560
Location: Greece

If you change the "Range("Q2").Value = -1
" with the below it will wait for one update
Code:
If Range("Q2").Value = -1 Then
    Range("Q2").ClearContents
Else
    Range("Q2").Value = -1
End If
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


DAJ Glass (1.0.8) template by Dustin Baccetti
EQ graphic based off of a design from www.freeclipart.nu
Powered by phpBB © 2001, 2005 phpBB Group