Article ID: 161760
Article Last Modified on 8/17/2005
APPLIES TO
- Microsoft Team Manager 1.0 Standard Edition
This article was previously published under Q161760
SYMPTOMS
You are using OLE Automation and you use the CreateObject function to start
Microsoft Team Manager. You then attempt to make Microsoft Team Manager
invisible by setting its Invisible property to False. Instead, you receive
the following error message:
Run-time error '1'
There was an OLE automation error.
Run-time error '-2147418113 (8000ffff)'
There was an OLE automation error.
CAUSE
Unlike other applications, such as Microsoft Excel and Microsoft Project,
Microsoft Team Manager doesn't allow you to set the application's Visible
property before you have opened a team file.
WORKAROUND
To work around this issue, open a team file before you attempt to set the
application's Visible property. The following code illustrates this:
Sub MakeTMInvisible()
Set TMGR = CreateObject("TeamManager.Application")
' Open a team file.
TMGR.Open False, "c:\Microsoft Team Manager\Sample.mtp"
' Set the application Visible property.
TMGR.Visible = False
End Sub
If you swap the above TMGR.Open and TMGR.Visible lines, you will receive an
error message.
STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.
MORE INFORMATION
Setting the application Visible property to False after using the
CreateObject function is a way to ensure that the application remains
invisible while the CreateObject variable is in scope. This allows you to
keep the application invisible from the user while your code interacts with
the application.
Microsoft Team Manager does not allow this. Therefore, you will temporarily
see your team file before you are able to set the Visible property.
Additional query words: Run time error 1 There was an OLE automation -2147418113 8000ffff
Keywords: kberrmsg kbbug kbpending KB161760