private void btn_add_Click(object sender, EventArgs e) { var member = CheckOnline(txt_username.Text, txt_password.Text); if (member == null || member.Id == Guid.Empty) { MessageBox.Show("Invalid Account, please try again"); return; } Global.Organizations.Clear(); foreach (var company in member.Company) { Global.Organizations.Add(new AssetOrganization { IraiCode = company.OrganizationCode, Name = company.OrganizationName, Email = company.OrganizationEmail, Handphone = company.ContactNumber, Phone = company.OrganizationPhone, IndustryCode = company.IndustryClassification, RegistrationNumber = company.OrganizationRegId, Website = company.OrganizationWebsite }); } lst_organisation.DataSource = Global.Organizations; lst_organisation.DisplayMember = "Name"; IraiCreator.UpdateDisplay(); }
public IraiCreator() { InitializeComponent(); Instance = this; }