MQL5 リファレンス標準ライブラリトレードクラスCPositionInfoSelectByMagic TimeTimeMscTimeUpdateTimeUpdateMscPositionTypeTypeDescriptionMagicIdentifierVolumePriceOpenStopLossTakeProfitPriceCurrentCommissionSwapProfitSymbolCommentInfoIntegerInfoDoubleInfoStringSelectSelectByIndexSelectByMagicSelectByTicketStoreStateCheckState SelectByMagic 商品名と今後の作業のマジックナンバーでポジションを選択します。 bool SelectByMagic( const string symbol, // 商品名 const ulong magic // マジックナンバー ); パラメータ symbol [in] 商品名。 magic [in] ポジションのマジックナンバー。 戻り値 成功した場合trueを返し、ポジションが選択されていない場合はfalseを返します。 SelectByIndex SelectByTicket