how to interpret the OmmTime.Hour's "Gets Hour. Range is 0 - 23 where 255 indicates blank." comme...

vnaik01
vnaik01 Newcomer

...nt (C#)

I am using C#, I am wondering how I should interpret the OmmTime.Hour's "Gets Hour. Range is 0 - 23 where 255 indicates blank." comment. Other fields of OmmTime, such as the Minute and Second fields, have similar description. Does it mean the entire OmmTime structure should be considered invalid?

screenshot-2024-05-07-15-22-59.png

Also, from another question I posted on the Refinitiv's forum: https://community.developers.refinitiv.com/questions/116730/how-to-handle-omminvalidusageexception-attempt-to.html

There is another generic way to check whether or not a field is empty. How should I understand the existence of these two seemingly identical features?


Best Answer

  • Jirapongse
    Jirapongse ✭✭✭✭✭
    Answer ✓

    @vnaik01

    Thank you for reaching out to us

    In EMA C#, you can check if the data is blank by using the following code.

        private static void Decode(FieldList fieldList)
        {
            foreach (FieldEntry fieldEntry in fieldList)
            {
                Console.Write("Fid: " + fieldEntry.FieldId + " Name = " + fieldEntry.Name + " DataType: " + DataType.AsString(fieldEntry.Load!.DataType) + " Value: ");


                if (Data.DataCode.BLANK == fieldEntry.Code)

    ...

    You can refer to the 290_Custom_Decode example in the RTSDK C# package.