>I need to add a custom toolbar in Word via automation only if it does not already exist. However, if I check to see if Word's commandbar already exists I get error number 1426. Here is the code I am using:
>
>
>oWord = CREATEOBJECT('Word.Application')
>ox = oWord.CommandBars('myNewToolbar')
>
>
>Is there a better way to check and see if the toolbar already exists?
local llExists
for each cbar in oWord.CommandBars
if lower(cbar.Name) = 'mynewtoolbar'
llExists = .t.
exit
endif
endfor
Cetin