In the WealthLab QuickReference guide, it says that for "SellAtTrailingStop()" that
"The trailing stop price is maintained with the Position, and it is modified only when the specified stopPrice is above the current trailing stop price. "Assuming you bought a stock at say $10, does that mean if you call SellAtTrailingStop() once with a stopPrice of $9 and then later call SellAtTrailingStop() with a stopPrice of $9.50 that the old stopPrice of $9 will be replaced with the new stopPrice of $9.50 for the trailing stop ?
In the code example in the QuickRef guide, there is a call to SellAtStop() and then SellAtTrailingStop(), so I'm unsure about the logic in the code below since the example is selling at a stop and then calling a function to sell at trailing stop again.
CODE:
Please log in to see this code.