public void getOrders() { BackupOpenOrders.Clear(); MyBackupOpenOrders.Clear(); filestream.Position = 0; while (filestream.Position != filestream.Length) { SerialOpenOrder r = formatter.Deserialize(filestream) as SerialOpenOrder; BackupOpenOrders.Add(r); if (r.ApiKey == this.apiKeyStore) { MyBackupOpenOrders.Add(r); } } return; }
public bool ordersToRestore() { return(MyBackupOpenOrders.Any()); }