Click here to Skip to main content
15,922,696 members
Home / Discussions / C#
   

C#

 
AnswerRe: Lock the PC Pin
PIEBALDconsult26-Oct-10 15:53
mvePIEBALDconsult26-Oct-10 15:53 
QuestionCOM Object with Protected Methods Pin
Enobong Adahada26-Oct-10 2:42
Enobong Adahada26-Oct-10 2:42 
AnswerRe: COM Object with Protected Methods Pin
Richard MacCutchan26-Oct-10 6:54
mveRichard MacCutchan26-Oct-10 6:54 
GeneralRe: COM Object with Protected Methods Pin
Enobong Adahada26-Oct-10 23:56
Enobong Adahada26-Oct-10 23:56 
GeneralRe: COM Object with Protected Methods Pin
Richard MacCutchan27-Oct-10 2:33
mveRichard MacCutchan27-Oct-10 2:33 
Questionopen form as a tab in windows applications Pin
Zeyad Jalil26-Oct-10 1:39
professionalZeyad Jalil26-Oct-10 1:39 
AnswerRe: open form as a tab in windows applications Pin
OriginalGriff26-Oct-10 1:49
mveOriginalGriff26-Oct-10 1:49 
GeneralRe: open form as a tab in windows applications Pin
Zeyad Jalil26-Oct-10 1:50
professionalZeyad Jalil26-Oct-10 1:50 
GeneralRe: open form as a tab in windows applications Pin
OriginalGriff26-Oct-10 1:56
mveOriginalGriff26-Oct-10 1:56 
GeneralRe: open form as a tab in windows applications Pin
Zeyad Jalil26-Oct-10 2:02
professionalZeyad Jalil26-Oct-10 2:02 
AnswerRe: open form as a tab in windows applications Pin
darkelv26-Oct-10 14:50
darkelv26-Oct-10 14:50 
Questionproblem with process.HasExited "No process is associated with this object error" Pin
prasadbuddhika26-Oct-10 1:20
prasadbuddhika26-Oct-10 1:20 
AnswerRe: problem with process.HasExited "No process is associated with this object error" Pin
Rajesh Anuhya26-Oct-10 1:39
professionalRajesh Anuhya26-Oct-10 1:39 
GeneralRe: problem with process.HasExited "No process is associated with this object error" Pin
prasadbuddhika26-Oct-10 1:48
prasadbuddhika26-Oct-10 1:48 
AnswerRe: problem with process.HasExited "No process is associated with this object error" Pin
Luc Pattyn26-Oct-10 2:13
sitebuilderLuc Pattyn26-Oct-10 2:13 
GeneralRe: problem with process.HasExited "No process is associated with this object error" Pin
Rajesh Anuhya26-Oct-10 2:37
professionalRajesh Anuhya26-Oct-10 2:37 
QuestionRestrict a file to be open Pin
jojoba201126-Oct-10 0:29
jojoba201126-Oct-10 0:29 
AnswerRe: Restrict a file to be open Pin
Richard MacCutchan26-Oct-10 0:47
mveRichard MacCutchan26-Oct-10 0:47 
AnswerRe: Restrict a file to be open Pin
OriginalGriff26-Oct-10 0:53
mveOriginalGriff26-Oct-10 0:53 
AnswerRe: Restrict a file to be open Pin
Pete O'Hanlon26-Oct-10 0:56
mvePete O'Hanlon26-Oct-10 0:56 
AnswerRe: Restrict a file to be open Pin
#realJSOP26-Oct-10 1:32
professional#realJSOP26-Oct-10 1:32 
GeneralRe: Restrict a file to be open Pin
Mirko198026-Oct-10 3:12
Mirko198026-Oct-10 3:12 
Questionproblem with purecomponents Pin
f_aliani25-Oct-10 23:24
f_aliani25-Oct-10 23:24 
AnswerRe: problem with purecomponents Pin
OriginalGriff25-Oct-10 23:37
mveOriginalGriff25-Oct-10 23:37 
QuestionVSTO outlook stopping fire events while running...? Pin
leeoze25-Oct-10 23:04
leeoze25-Oct-10 23:04 
Hi I'm writing an outlook addin in VisuaStudio 2008 using the buildin Outlook addin project template of VS2008.

In my code I added a new button to one of the ActiveExplorer() commandbars.
I made it changed according to the number of items selected in the ActiveExplorer
using Application.ActiveExplorer().SelectionChange event.

this works just fine up until I click on the button and load my winForm. after doing so it seems like the Application events that I used (including : SelectionChange and ItemContextMenuDisplay) stopped triggered. and the button as a result stopped changing according to the number of items selected.

The winform is empty and loads up as ShowDialog.

Any ideas why and how to fix it? tnx leeoz

here is part of the relevant code (I only missed out the AddMenuBar(), ThisAddIn_Shutdown() and the other events which have the same problem after showing this winForm):

private void InternalStartup()
        {
            this.Application.ItemContextMenuDisplay +=new Microsoft.Office.Interop.Outlook.ApplicationEvents_11_ItemContextMenuDisplayEventHandler(Application_ItemContextMenuDisplay);
            this.Application.ContextMenuClose +=new Microsoft.Office.Interop.Outlook.ApplicationEvents_11_ContextMenuCloseEventHandler(Application_ContextMenuClose);
            this.Application.ActiveExplorer().SelectionChange += new Microsoft.Office.Interop.Outlook.ExplorerEvents_10_SelectionChangeEventHandler(ThisAddIn_SelectionChange);
            this.Startup += new System.EventHandler(ThisAddIn_Startup);            
            this.Shutdown += new System.EventHandler(ThisAddIn_Shutdown);
        }



void ThisAddIn_SelectionChange()
        {
            if (btnManualFiling != null)
            {
                if (this.Application.ActiveExplorer().Selection.Count > 0)
                {

                    btnManualFiling.Enabled = true;                    

                }
                else
                {
                    btnManualFiling.Enabled = false;                    
                }
                CurrentSelection = this.Application.ActiveExplorer().Selection.Count.ToString();
                btnManualFiling.Caption = TomaxManCaption + "(" + CurrentSelection + " items)";
            }
        }

private void ThisAddIn_Startup(object sender, System.EventArgs e)
        {
                        AddMenuBar();
         }

private void buttonOne_Click(Office.CommandBarButton ctrl, ref bool cancel)
        {            
            frmManualFiling wnd = new frmManualFiling(this.Application);
            wnd.ShowDialog();
            wnd.Dispose();
            wnd = null;
            
         }

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.