private void SpecialSettingEditor_Load(object sender, EventArgs e) { if (SpecialSetting == null) { throw new InvalidOperationException("SpecialSetting is not set."); } if (String.IsNullOrEmpty(ObjectName)) { throw new InvalidOperationException("ObjectName is not set."); } Text = String.Format(SpecialSettingResources.EditorCaption, ObjectName); labelHelp.Text = SpecialSetting.HelpText; if (!String.IsNullOrEmpty(TargetRule)) { textEditor.RichTextBox.Text = SpecialSetting.ConvertTo(TargetRule); } }