Documentation Center

  • Trial Software
  • Product Updates

deleteRoute

Delete Bloomberg EMSX route

Syntax

  • R = deleteRoute(c,reqStruct) example
  • R = deleteRoute(c,reqStruct,Name,Value) example

Description

example

R = deleteRoute(c,reqStruct) deletes a Bloomberg® EMSX route and returns a status message using the default event handler.

example

R = deleteRoute(c,reqStruct,Name,Value) uses additional options specified by one or more Name, Value pair arguments. Delete a Bloomberg EMSX route using optional name-value arguments to specify a custom event handler or timeout value for the event handler.

    Note:   Name-value pair arguments can be input as a single input structure containing some or all of the property fields, for example:

    p.timeOut = 1000;
    deleteRoute(c,reqStruct,p)

Examples

expand all

Delete Route for Bloomberg EMSX Order Using Default Event Handler

Define the reqStruct values for EMSX_SEQUENCE and EMSX_ROUTE_ID. Then delete the route.

reqStruct.EMSX_SEQUENCE = int32(335877)
reqStruct.EMSX_ROUTE_ID = int32(1)
r = deleteRoute(c,reqStruct)
 r = 
    
      STATUS: '0'
     MESSAGE: 'Route deleted'

Delete Route for Bloomberg EMSX Order Using Custom Event Handler

Define the reqStruct values for EMSX_SEQUENCE and EMSX_ROUTE_ID. Then delete the route.

reqStruct.EMSX_SEQUENCE = int32(335877)
reqStruct.EMSX_ROUTE_ID = int32(1)  
deleteRoute(c,reqStruct,'useDefaultEventHandler',false)
processEvent(c)
DeleteRoute = {
 
        STATUS = 0
 
        MESSAGE = Route deleted
 
    }

Delete Route for Bloomberg EMSX Order Using timeOut Value

Define the reqStruct values for EMSX_SEQUENCE and EMSX_ROUTE_ID. Then delete the route.

reqStruct.EMSX_SEQUENCE = int32(335877)
reqStruct.EMSX_ROUTE_ID = int32(1)  
deleteRoute(c,int32(335877),'timeOut',200)
 r = 
    
      STATUS: '0'
     MESSAGE: 'Route deleted'

Input Arguments

expand all

c — Connection object for Bloomberg EMSX serviceobject structure

Connection object for Bloomberg EMSX service, specified using emsx.

reqStruct — Order request structurestructure | integer for EMSX_SEQUENCE number

Order request structure, specified as a reqStruct or EMSX_SEQUENCE number.

Example: reqStruct.EMSX_TICKER = 'XYZ';
reqStruct.EMSX_AMOUNT = int32(100);
reqStruct.EMSX_ORDER_TYPE = 'MKT';
reqStruct.EMSX_TIF = 'DAY';
reqStruct.EMSX_HAND_INSTRUCTION = 'ANY';
reqStruct.EMSX_SIDE = 'BUY';

Data Types: int32 | struct

Name-Value Pair Arguments

Specify optional comma-separated pairs of Name,Value arguments. Name is the argument name and Value is the corresponding value. Name must appear inside single quotes (' '). You can specify several name and value pair arguments in any order as Name1,Value1,...,NameN,ValueN.

Example: deleteRoute(c,reqStruct,'useDefaultEventHandler',false)

'useDefaultEventHandler' — Flag for event handler preferencetrue (default) | logical with value true or false

Flag for event handler preference, indicating whether to use the default or custom event handler to process order events, as specified by the string true or false. When this flag is set to the default, true, the default event handler is used. If a custom event handler is used, this flag must be set to false.

Example: 'useDefaultEventHandler',false

Data Types: logical

'timeOut' — Connection timeout value for event handler for Bloomberg EMSX service500 milliseconds (default) | nonnegative integer

Connection timeout value, specified as a nonnegative integer in units of milliseconds.

Example: 'timeOut',200

Data Types: char

Output Arguments

expand all

R — Return status for requested eventstructure

Return status for the order event returned as a structure.

See Also

| | | |

Was this topic helpful?