This code works perfectly ok when I trade Equity Stocks, but when I try to place orders for Futures and Options, This always gives me error : Invalid Trading symbol. For example, if I want to Buy or Sell 100 stocks of RELIANCE, then I provide the trading symbol as 'RELIANCE' and the order gets executed successfully, but If i try to Buy or Sell 1 LOT of RELIANCE FUTURES and provide the trading symbol as 'RELIANCE21DECFUT' then this will throw an error invalid trading symbol.
This problem persists for all the Future instruments of any stock, as well as options instruments it is not specific to only one particular instrument, I am not able to run algorithmic trading program for future and options segment due to this issue, though it is working fine for equity segment. Not able to understand/solve the issue.