private void InitializeHtmlEditor() { PredefinedButtonSets.SetupDefaultButtons(this.htmlEditor); this.htmlEditor.DocumentTextChanged += (s, e) => { if (this.workspace != null) { this.workspace.Content = this.htmlEditor.Html; } }; this.htmlEditor.DocumentPreviewKeyDown += async(kds, kde) => { if (kde.KeyData == (Keys.Control | Keys.S)) { await this.DoSaveAsync(); } }; }
public MOM_Form(String calendarEntryId, Microsoft.Office.Interop.Outlook.MAPIFolder calendar, Microsoft.Office.Interop.Outlook._NameSpace ns, String inviteeList, Dictionary <String, String> mapDict, Microsoft.Office.Interop.Outlook.Application appl) { InitializeComponent(); panel1.Height = 30; panel_next_meeting_atch1.Height = 25; btnMenuGroup1.Image = MOMOutlookAddIn.Properties.Resources.down; //This method will initialize the button toolbar for the text editor PredefinedButtonSets.SetupDefaultButtons(this.meetingNotes); //PredefinedButtonSets.SetupDefaultButtons(this.nextMeetingBody); //meetingNotes.ShowSelectionMargin = true; if (mapDict != null) { emailNameMappingDict = mapDict; } else { emailNameMappingDict = new Dictionary <string, string>(); } app = appl; populateTimeCombo(); button_Add_Action.Enabled = false; Outlook.AppointmentItem calItem = (Outlook.AppointmentItem)ns.GetItemFromID(calendarEntryId, calendar.StoreID); if (calItem != null) { meetingname.Text = calItem.Subject.Trim(); meetingDate.Text = calItem.Start.ToString().Substring(0, calItem.Start.ToString().IndexOf(" ")); starttime.Text = calItem.Start.ToString().Substring(calItem.Start.ToString().IndexOf(" ") + 1); endtime.Text = calItem.End.ToString().Substring(calItem.End.ToString().IndexOf(" ") + 1); location.Text = calItem.Location != null?calItem.Location.Trim() : ""; minutestaken.Text = System.DirectoryServices.AccountManagement.UserPrincipal.Current.DisplayName; chair.Text = calItem.Organizer.Trim(); inviteeListString = inviteeList; nextMeetingItem = findNextOccuranceOfThisMeeting(meetingname.Text, calendar, calItem, inviteeList); populateAssignedToListBoxAndAttendeeCheckBox(); } //minutestaken.Text=calItem.c }