CloseAllByHedge
Posted by Ismail Moamer, Last modified by Laith Ghawi on 01 July 2019 01:20 PM

Syntax

Public Function CloseAllByHedge(AccountID As Integer, BuyTickets As String, SellTickets As String, BuyLots as String, SellLots as String, SymbolID as Integer) CallingResultsEnum

Description

The CloseAllByHedge function is used to close the given tickets numbers(Sell and buy tickets) by hedge for a specific symbol, After CloseAllByHedge method executes the CloseByHedgeResultReceived event fire.

Parameters

Parameters Description 
AccountID Account number to close tickets by hedge for , value of type is Integer
BuyTickets The Tickets number for the buy position separated by ",", value of type is String
SellTickets The Tickets number for the Sell position separated by ",", value of type is String
BuyLots The lots value  for the buy position separated by "," , value of type is String
SellLots The lots value  for the sell position separated by "," , value of type is String
SymbolID Symbol number  for the positions that wants to closed it by hedge, Value of type is Integer

Return value

Returns value of type CallingResultsEnum, if the request sent to the server successfully it will return SuccessResult.

Sample


Public WithEvents m_oBOAPI As CVertexFXBOAPI 

Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

          Dim result As VertexFXBOAPI11.CallingResultsEnum

          Dim AccountID as Integer = "1234567" 'Change it with your accountID

          Dim BuyTickets as String = "695487,695488"   

          Dim SellTickets as String = "695470,695471"    

          Dim BuyLots as String = "0.1,0.1"        

          Dim SellLots as String = "0.1,0.1"                

   result = m_oBOAPI.CloseAllByHedge(AccountID, BuyTickets, SellTickets, BuyLots, SellLots,6)
     MsgBox(result.ToString)

 End Sub




See Also


VertexFX Backoffice API Index

(0 vote(s))
Helpful
Not helpful

Comments (0)
Post a new comment
 
 
Full Name:
Email:
Comments:
CAPTCHA Verification 
 
Please enter the text you see in the image into the textbox below (we use this to prevent automated submissions).

Help Desk Software by Hybrid Solutions