public IEnumerable <IDestination> Destinations() { IDestination destination = null; try { destination = new ExcelDestination(); } catch { destination = null; } if (destination != null) { yield return(destination); } try { destination = new PowerpointDestination(); } catch { destination = null; } if (destination != null) { yield return(destination); } try { destination = new WordDestination(); } catch { destination = null; } if (destination != null) { yield return(destination); } try { destination = new OutlookDestination(); } catch { destination = null; } if (destination != null) { yield return(destination); } try { destination = new OneNoteDestination(); } catch { destination = null; } if (destination != null) { yield return(destination); } }
public IEnumerable<IDestination> Destinations() { IDestination destination; try { destination = new ExcelDestination(); } catch { destination = null; } if (destination != null) { yield return destination; } try { destination = new PowerpointDestination(); } catch { destination = null; } if (destination != null) { yield return destination; } try { destination = new WordDestination(); } catch { destination = null; } if (destination != null) { yield return destination; } try { destination = new OutlookDestination(); } catch { destination = null; } if (destination != null) { yield return destination; } try { destination = new OneNoteDestination(); } catch { destination = null; } if (destination != null) { yield return destination; } }