def updatePortfolio(self, contract, position, marketPrice, marketValue, averageCost, unrealizedPNL, realizedPNL, accountName):
self.myvariable = position
def cxlAccountUpdates(self):
self.connection.reqAccountUpdates(False,"DU666")
PM me. I will write it for you