mirror of
https://github.com/greenshot/greenshot
synced 2025-08-14 02:37:03 -07:00
Activation (display) fixes for Outlook/Word
git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@2580 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
parent
6629d383c9
commit
55f52bd658
2 changed files with 18 additions and 2 deletions
|
@ -283,6 +283,12 @@ namespace Greenshot.Interop.Office {
|
|||
LOG.WarnFormat("Problem while trying to add attachment to Item '{0}' : {1}", inspector.Caption, ex);
|
||||
return false;
|
||||
}
|
||||
try {
|
||||
inspector.Activate();
|
||||
} catch (Exception ex) {
|
||||
LOG.Warn("Problem activating inspector: ", ex);
|
||||
return false;
|
||||
}
|
||||
LOG.Debug("Finished!");
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -142,8 +142,18 @@ namespace Greenshot.Interop.Office {
|
|||
}
|
||||
}
|
||||
}
|
||||
wordDocument.Activate();
|
||||
wordDocument.ActiveWindow.Activate();
|
||||
try {
|
||||
wordApplication.Activate();
|
||||
} catch {
|
||||
}
|
||||
try {
|
||||
wordDocument.Activate();
|
||||
} catch {
|
||||
}
|
||||
try {
|
||||
wordDocument.ActiveWindow.Activate();
|
||||
} catch {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue