hello,

I was successfully using the following code as entering orders to
trade commodity futures in to exchange.

Private Sub Worksheet_Calculate()
Const WS_RANGE As String = "B1" '<== change to suit
On Error GoTo ws_exit
If Range(WS_RANGE).Value = oldval Then Exit Sub 'value has not changed
oldval = Range(WS_RANGE).Value
Application.EnableEvents = False
If Range(WS_RANGE).Value > Range("b2") And Range(WS_RANGE).Value <
Range("b3") Then 'range 1 and range 2
Call BuyBeansSellProducts
End If
If Range(WS_RANGE).Value >= Range("b5") And Range(WS_RANGE).Value <
Range(" b6") Then 'range3 and range4
Call SellBeansBuyProducts
End If
ws_exit:
Application.EnableEvents = True
End Sub

The problem is; my code suddenly stopped recognizing range 3 and range
4 and dpes not call SellBEANBUYPRODUCTS anymore but works greate for
range1 and range2 and calls BUYBEANSSELLPRODUCTS...

When i run seperately SellBeansBuyProducts macro it also runs without
any issues..

Any idea what is causing it?

--~--~---------~--~----~------------~-------~--~----~
----------------------------------------------------------------------------------
Some important links for excel users:
1. Excel and VBA Tutorials(Video and Text), Free add-ins downloads at 
http://www.excelitems.com
2. Excel tutorials at http://www.excel-macros.blogspot.com
3. Learn VBA Macros at http://www.vbamacros.blogspot.com
4. Excel Tips and Tricks at http://exceldailytip.blogspot.com
 

To post to this group, send email to excel-macros@googlegroups.com
If you find any spam message in the group, please send an email to:
Ayush Jain  @ jainayus...@gmail.com or
Ashish Jain @ 26may.1...@gmail.com
<><><><><><><><><><><><><><><><><><><><><><>
HELP US GROW !!

We reach over 5,000 subscribers worldwide and receive many nice notes about the 
learning and support from the group. Our goal is to have 10,000 subscribers by 
the end of 2009. Let friends and co-workers know they can subscribe to group at 
http://groups.google.com/group/excel-macros/subscribe
-~----------~----~----~----~------~----~------~--~---

Reply via email to