private void AddClientAdd() { ClientAdd client = new ClientAdd(); ClientAddCollection.Add(client); SelectedClientAdd = client; MessageBox.Show("Click Save button after entering the new Client Address details.", "Client Location", MessageBoxButton.OK, MessageBoxImage.Warning); }
public ClientAddManagementViewModel(string ClientId) { //1. Its going to connect to DAL and bring in the results of all Instructors //2. we Create objects of type instructor and then add that object to our collection DAL dal = new DAL(); DataTable dt = dal.Read("Select * from bit_client_location where Client_Id=" + ClientId); PassedClientId = Convert.ToInt32(ClientId); // clientadd.UserID = UserId; foreach (DataRow dr in dt.Rows) { ClientAdd client = new ClientAdd(dr); ClientAddCollection.Add(client); } }