View Full Version : Word flashing on screen when closing using ActiveXObject('Word.Application')

07-29-2008, 08:16 AM
I just can't seem to remove the flashing of Word window when the spell check is complete...

When user clicks on button to correct a text field everyting works fine only the "spelling" dialog box pops up no flashing but when the check is complete
and the dialog box is closed Word flashes the screen before closing down.

is there a way to remove this behavior ?
any ideas would be greatly appreciated.

if (obj_word) {

// do not show app window
obj_word.Visible = false;

// create a new instance of document
var obj_word_doc = obj_word.Documents.Add();

// check spelling
obj_word.Selection.Text = text_value;

if (obj_word.Selection.Text.length != 1) {
str_corrected = obj_word.Selection.Text;
} else {
str_corrected = text_value;

// close word doc and app

// return spell check completed text data
document.getElementById(text_field).value = str_corrected;