4.1 Sample Note Object
Joe creates a Note object, types in his grocery list, and saves it. The following is a description of what a client might do to accomplish Joe's intentions and the responses a server might return.
This example uses both named properties and tagged properties of a Note object. The property ID of a named property is provided by the server. Therefore, before setting or reading any properties of a Note object, the client asks the server to perform a mapping from property names or long IDs (LIDs) to property IDs. To request this mapping, the client sends a RopGetPropertyIdsFromNames ROP request ([MS-OXCROPS] section 2.2.8.1).
The following table lists each named property with its named property set GUID and its long ID (LID) or property name. The server's RopGetPropertyIdsFromNames ROP response provides the corresponding property IDs, as shown in the subsequent table.
Property |
Property set GUID |
LID |
---|---|---|
PidLidNoteColor (section 2.2.1.1) |
{0006200E-0000-0000-C000-000000000046} |
0x00008B00 |
PidLidNoteWidth (section 2.2.1.2) |
{0006200E-0000-0000-C000-000000000046} |
0x00008B02 |
PidLidNoteHeight (section 2.2.1.3) |
{0006200E-0000-0000-C000-000000000046} |
0x00008B03 |
PidLidNoteX (section 2.2.1.4) |
{0006200E-0000-0000-C000-000000000046} |
0x00008B04 |
PidLidNoteY (section 2.2.1.5) |
{0006200E-0000-0000-C000-000000000046} |
0x00008B05 |
The following table lists the property IDs that might be provided in the server's RopGetPropertyIdsFromNames ROP response. The actual property IDs returned are at the discretion of the server.
Property |
Property ID |
---|---|
PidLidNoteColor |
0x8046 |
PidLidNoteWidth |
0x8047 |
PidLidNoteHeight |
0x8048 |
PidLidNoteX |
0x8049 |
PidLidNoteY |
0x804A |
To create a Note object, the client uses the RopCreateMessage ROP ([MS-OXCROPS] section 2.2.6.2). The server returns a success code and a handle to a Message object.
After Joe has input his content for the Note object, the client transmits the properties of the Note object to the server by using the RopSetProperties ROP ([MS-OXCROPS] section 2.2.8.6). The properties that are set on the Note object are shown in the following table. For information about property types in the following table, see[MS-OXCDATA] section 2.11.1.
Property |
Property ID |
Property type |
Value |
---|---|---|---|
PidLidNoteColor |
0x8046 |
0x0003 (PtypInteger32) |
0x00000003 |
PidLidNoteWidth |
0x8047 |
0x0003 |
0x000000C8 |
PidLidNoteHeight |
0x8048 |
0x0003 |
0x000000A6 |
PidLidNoteX |
0x8049 |
0x0003 |
0x0000006E |
PidLidNoteY |
0x804A |
0x0003 |
0x0000006E |
PidTagIconIndex ([MS-OXOMSG] section 2.2.1.10) |
0x1080 |
0x0003 |
0x00000303 |
PidTagMessageClass ([MS-OXCMSG] section 2.2.1.3) |
0x001A |
0x001F (PtypString) |
"IPM.StickyNote" |
PidTagNormalizedSubject ([MS-OXCMSG] section 2.2.1.10) |
0x0E1D |
0x001F |
"Grocery List" |
PidTagSubjectPrefix ([MS-OXCMSG] section 2.2.1.9) |
0x003D |
0x001F |
"" (null) |
PidTagBody ([MS-OXCMSG] section 2.2.1.58.1) |
0x1000 |
0x001F |
"Grocery List: Celery Broccoli" |
When Joe is ready to save his changes, the client commits the properties on the server by using the RopSaveChangesMessage ROP ([MS-OXCROPS] section 2.2.6.3) and then releases the Note object by using the RopRelease ROP ([MS-OXCROPS] section 2.2.15.3).
The values of some properties of the Message object will change during the execution of the RopSaveChangesMessage ROP, but the properties specified in this document will not change.