Share via


CLSID Property

Contains the registered CLSID (Class Identifier) for a server in a project. Read-only at design time and run time.

Object.CLSID

Remarks

A CLSID is created in the Windows registry for a server when you build an executable file (.exe) or dynamic link library (.dll) from a project.

Example

The following example demonstrates a use of the CLSID property after creation of a COM server (.dll).

* In a program("Testclass.prg"), create a class
DEFINE CLASS myclass AS SESSION OLEPUBLIC 
ENDDEFINE
...

In a project, include the .prg file in a .dll or MTDLL Build. The server object properties are then available by code access. For example, in the Command window, type the following:

MyServer = _VFP.ActiveProject.Servers("myclass")
? "Class ID is ", MyServer.CLSID      && Class ID is {620E56FE-F7F8-4E99-B767-CB08009261F0} 
                                    && a GUID
? "Description is ", MyServer.Description    && testclass.myclass

See Also

CREATEOBJECTEX( ) | ProgID Property | TypeLibCLSID Property | TypeLibDesc Property | TypeLibName Property

Applies To: Server Object