private void DisplayCAT62I105Data()
{
if (MainASTERIXDataStorage.CAT62Message.Count > 0)
{
this.listBoxMainDataBox.Items.Add("Detailed view of: " + MainASTERIXDataStorage.CAT62Message[0].CAT62DataItems[CAT62.ItemIDToIndex("010")].Description);
ASTERIX.SIC_SAC_Time SIC_SAC_TIME = (ASTERIX.SIC_SAC_Time)MainASTERIXDataStorage.CAT62Message[0].CAT62DataItems[CAT62.ItemIDToIndex("010")].value;
this.listBoxMainDataBox.Items.Add("SIC/SAC: " + SIC_SAC_TIME.SIC.ToString() + "/" + SIC_SAC_TIME.SAC.ToString());
this.listBoxMainDataBox.Items.Add(" ");
// Here determine the flag indicating what data is to be shown
foreach (MainASTERIXDataStorage.CAT62Data Msg in MainASTERIXDataStorage.CAT62Message)
{
if (Msg.CAT62DataItems[CAT62.ItemIDToIndex("105")].value != null)
{
SIC_SAC_TIME = (ASTERIX.SIC_SAC_Time)Msg.CAT62DataItems[CAT62.ItemIDToIndex("010")].value;
// Display time
string Time = SIC_SAC_TIME.TimeofReception.Hour.ToString().PadLeft(2, '0') + ":" + SIC_SAC_TIME.TimeofReception.Minute.ToString().PadLeft(2, '0') + ":" +
SIC_SAC_TIME.TimeofReception.Second.ToString().PadLeft(2, '0') + ":" + SIC_SAC_TIME.TimeofReception.Millisecond.ToString().PadLeft(3, '0');
this.listBoxMainDataBox.Items.Add("Rcvd Time: " + Time);
GeoCordSystemDegMinSecUtilities.LatLongClass MyData = (GeoCordSystemDegMinSecUtilities.LatLongClass)Msg.CAT62DataItems[CAT62.ItemIDToIndex("105")].value;
string Lat, Lon = "";
MyData.GetDegMinSecStringFormat(out Lat, out Lon);
this.listBoxMainDataBox.Items.Add("\tLat: " + Lat);
this.listBoxMainDataBox.Items.Add("\tLon: " + Lon);
this.listBoxMainDataBox.Items.Add(" ");
}
}
}
else
{
this.listBoxMainDataBox.Items.Add("No data of this CAT/Item was received !!!");
}
}