The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.



Loads file-type information from the document-template string and places that information in the OLE system registry.

      void UpdateRegistry( 
   LPCTSTR* rglpszRegister = NULL, 
   LPCTSTR* rglpszOverwrite = NULL, 
   BOOL bRegister = TRUE  


A value from the OLE_APPTYPE enumeration, which is defined in AFXDISP.H. It can have any one of the following values:

  • OAT_INPLACE_SERVER   Server has full server user-interface.

  • OAT_SERVER   Server supports only embedding.

  • OAT_CONTAINER   Container supports links to embedded objects.

  • OAT_DISPATCH_OBJECT   Object is IDispatch-capable.

  • OAT_DOC_OBJECT_SERVER   Server supports both embedding and the Document Object component model.


A list of entries that is written into the registry only if no entries exist.


A list of entries that is written into the registry regardless of whether any preceding entries exist.


Determines whether the class is to be registered. If bRegister is TRUE, the class is registered with the system registry. Otherwise, it unregisters the class.

The registration information is loaded by means of a call to CDocTemplate::GetDocString. The substrings retrieved are those identified by the indexes regFileTypeId, regFileTypeName, and fileNewName, as described in the GetDocString reference pages.

If the regFileTypeId substring is empty or if the call to GetDocString fails for any other reason, this function fails and the file information is not entered in the registry.

The information in the arguments rglpszRegister and rglpszOverwrite is written to the registry through a call to AfxOleRegisterServerClass. The default information, which is registered when the two arguments are NULL, is suitable for most applications. For information on the structure of the information in these arguments, see AfxOleRegisterServerClass.

For more information, see 0e171f7f-0022-4e9b-ac8e-98192828e945.


Header: afxdisp.h