get the broker position from the account

 

Loop through all open positions, filter by symbol, sum up lots.

Since there are no slaves here, you have only three choices: Search for it, learn to code it, or pay someone. We're not going to code it FOR you. We are willing to HELP you when you post your attempt and the nature of your problem.

Reason: