private void control_Loaded(object sender, RoutedEventArgs e) { try { this.cmb_Server.ItemsSource = dC_Service.GetDCServers(); this.cmb_Crane.ItemsSource = dC_Service.GetCranes().DefaultView; } catch (Exception) { } }
public u_Device(DC_DEVICE device) { Device = device; DC_Service dC_Service = new DC_Service(); try { Cranes = dC_Service.GetCranes(); } catch (Exception) { } InitializeComponent(); }
public w_Device(DC_SERVER server) { Device.SERVER_ID = server.ID; DC_Service dC_Service = new DC_Service(); try { DataTable dt = dC_Service.GetCranes(); DataRow row = dt.NewRow(); row["CRA_NAME"] = "不是天车选这个"; dt.Rows.InsertAt(row, 0); Cranes = dt; } catch (Exception) { } InitializeComponent(); }
public w_Device(DC_DEVICE device) { IsModify = true; Device = device; DC_Service dC_Service = new DC_Service(); try { DataTable dt = dC_Service.GetCranes(); DataRow row = dt.NewRow(); row["CRA_NAME"] = "不是天车选这个"; dt.Rows.InsertAt(row, 0); Cranes = dt; } catch (Exception) { } InitializeComponent(); }