예제 #1
0
 private void SetUpGeneral()
 {
     HideTpfDetailsTab();
     FileNameTextBox.Text     = File.FileName;
     FileIdTextBox.Text       = File.FileId.ToString(CultureInfo.CurrentCulture);
     FormatTextBox.Text       = File.LookupCollarParameterFileFormat.Name;
     UserNameTextBox.Text     = File.UploadUser;
     UploadDateTextBox.Text   = File.UploadDate.ToString(CultureInfo.CurrentCulture);
     OwnerComboBox.DataSource =
         Database.ProjectInvestigators.Where(
             pi =>
             pi.Login == CurrentUser || pi.ProjectInvestigatorAssistants.Any(a => a.Assistant == CurrentUser));
     OwnerComboBox.DisplayMember  = "Name";
     OwnerComboBox.SelectedItem   = File.ProjectInvestigator;
     StatusComboBox.DataSource    = Database.LookupFileStatus;
     StatusComboBox.DisplayMember = "Name";
     StatusComboBox.SelectedItem  = File.LookupFileStatus;
     EnableGeneralControls();
     DoneCancelButton.Focus();
 }
예제 #2
0
 protected override void OnLoad(EventArgs e)
 {
     base.OnLoad(e);
     DoneCancelButton.Focus();
     FileTabControl_SelectedIndexChanged(null, null);
 }