Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Exchange
2000.active.directory
2000.admin
2000.announcements
2000.app.conversion
2000.applications
2000.clients
2000.clustering
2000.connectivity
2000.development
2000.documentation
2000.general
2000.information.store
2000.interop
2000.kms
2000.misc
2000.protocols
2000.realtime.collabo.
2000.setup
2000.transport
2000.win2000
admin
application.conversion
applications
clients
clustering
connectivity
design
development
misc
mobility
setup
tools
  
 
date: Mon, 05 Nov 2007 08:53:29 -0800,    group: microsoft.public.exchange.development        back       


EWS: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
Hello,

I try to get a Gid23 from an appointment, using this XML:

<GetItem xmlns="http://schemas.microsoft.com/exchange/services/2006/
messages">
      <ItemShape>
        <t:BaseShape>IdOnly</t:BaseShape>
        <t:AdditionalProperties>
           <t:ExtendedFieldURI
PropertySetId="6ED8DA90-450B-101B-98DA-00AA003F1305"
PropertyName="Gid23" PropertyType="Binary"/> <!-- first try -->
           <t:ExtendedFieldURI
PropertySetId="6ED8DA90-450B-101B-98DA-00AA003F1305"
PropertyId="00030102" PropertyType="Binary"/> <!-- second try -->
           <t:ExtendedFieldURI
PropertySetId="6ED8DA90-450B-101B-98DA-00AA003F1305"
PropertyId="30102" PropertyType="Binary"/> <!-- third try -->
        </t:AdditionalProperties>
      </ItemShape>

The XML is accepted by the Exchange 2007 server (Success response),
but the required propertie is not returned,

Does anyone have any idea about that ?

Thanks,

Dom.
date: Mon, 05 Nov 2007 08:53:29 -0800   author:   Dom

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
If its a custom property that GUID doesn't look right you should be using 
the PublicStrings GUID 00020329-0000-0000-C000-000000000046 or its easier 
just to use the DistinguishedPropertySetId eg

<t:ExtendedFieldURI DistinguishedPropertySetId="PublicStrings" 
PropertyName="Gid23" PropertyType="Integer"/>

You might want to try confirming this using a mapi editor first

Cheers
Glen



"Dom"  wrote in message 
news:1194281609.847677.92590@d55g2000hsg.googlegroups.com...
> Hello,
>
> I try to get a Gid23 from an appointment, using this XML:
>
> <GetItem xmlns="http://schemas.microsoft.com/exchange/services/2006/
> messages">
>      <ItemShape>
>        <t:BaseShape>IdOnly</t:BaseShape>
>        <t:AdditionalProperties>
>           <t:ExtendedFieldURI
> PropertySetId="6ED8DA90-450B-101B-98DA-00AA003F1305"
> PropertyName="Gid23" PropertyType="Binary"/> <!-- first try -->
>           <t:ExtendedFieldURI
> PropertySetId="6ED8DA90-450B-101B-98DA-00AA003F1305"
> PropertyId="00030102" PropertyType="Binary"/> <!-- second try -->
>           <t:ExtendedFieldURI
> PropertySetId="6ED8DA90-450B-101B-98DA-00AA003F1305"
> PropertyId="30102" PropertyType="Binary"/> <!-- third try -->
>        </t:AdditionalProperties>
>      </ItemShape>
>
> The XML is accepted by the Exchange 2007 server (Success response),
> but the required propertie is not returned,
>
> Does anyone have any idea about that ?
>
> Thanks,
>
> Dom.
>
date: Tue, 6 Nov 2007 10:47:33 +1100   author:   Glen Scales [MVP]

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
Hello Glen,

I've tried all this combinations:

           <t:ExtendedFieldURI
DistinguishedPropertySetId="PublicStrings" PropertyName="Gid23"
PropertyType="Binary"/>
           <t:ExtendedFieldURI
DistinguishedPropertySetId="PublicStrings"
PropertyName="cleanglobalobjid" PropertyType="Binary"/>
           <t:ExtendedFieldURI
DistinguishedPropertySetId="PublicStrings" PropertyName="global_objid"
PropertyType="Binary"/>
           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
C000-000000000046" PropertyName="cleanglobalobjid"
PropertyType="Binary"/>
           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
C000-000000000046" PropertyName="global_objid" PropertyType="Binary"/>
           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
C000-000000000046" PropertyName="Gid23" PropertyType="Binary"/>

but the Exchange 2007 Server's bahaviour remains the same: "Success
response", but no propertie returned.....

Dom.
date: Tue, 06 Nov 2007 01:17:45 -0800   author:   Dom

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
What does the full xml of your request look like in your previous post you 
had the shape set to IdOnly you might want to try changing this to Default 
or AllProperties.

Cheers
Glen


I
"Dom"  wrote in message 
news:1194340665.668683.306350@d55g2000hsg.googlegroups.com...
> Hello Glen,
>
> I've tried all this combinations:
>
>           <t:ExtendedFieldURI
> DistinguishedPropertySetId="PublicStrings" PropertyName="Gid23"
> PropertyType="Binary"/>
>           <t:ExtendedFieldURI
> DistinguishedPropertySetId="PublicStrings"
> PropertyName="cleanglobalobjid" PropertyType="Binary"/>
>           <t:ExtendedFieldURI
> DistinguishedPropertySetId="PublicStrings" PropertyName="global_objid"
> PropertyType="Binary"/>
>           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
> C000-000000000046" PropertyName="cleanglobalobjid"
> PropertyType="Binary"/>
>           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
> C000-000000000046" PropertyName="global_objid" PropertyType="Binary"/>
>           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
> C000-000000000046" PropertyName="Gid23" PropertyType="Binary"/>
>
> but the Exchange 2007 Server's bahaviour remains the same: "Success
> response", but no propertie returned.....
>
> Dom.
>
date: Wed, 7 Nov 2007 16:57:12 +1100   author:   Glen Scales [MVP]

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
Here is the full XML of my request:

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xmlns:xsd="http://www.w3.org/2001/XMLSchema"
               xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
               xmlns:t="http://schemas.microsoft.com/exchange/services/
2006/types">
  <soap:Body>
    <GetItem xmlns="http://schemas.microsoft.com/exchange/services/
2006/messages">
      <ItemShape>
        <t:BaseShape>AllProperties</t:BaseShape>
        <t:AdditionalProperties>
           <t:ExtendedFieldURI
PropertySetId="6ED8DA90-450B-101B-98DA-00AA003F1305"
PropertyName="Gid23" PropertyType="Binary"/> <!-- first try -->
           <t:ExtendedFieldURI
DistinguishedPropertySetId="PublicStrings" PropertyName="Gid23"
PropertyType="Binary"/>
           <t:ExtendedFieldURI
DistinguishedPropertySetId="PublicStrings"
PropertyName="cleanglobalobjid" PropertyType="Binary"/>
           <t:ExtendedFieldURI
DistinguishedPropertySetId="PublicStrings" PropertyName="global_objid"
PropertyType="Binary"/>
           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
C000-000000000046" PropertyName="cleanglobalobjid"
PropertyType="Binary"/>
           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
C000-000000000046" PropertyName="global_objid" PropertyType="Binary"/>
           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
C000-000000000046" PropertyName="Gid23" PropertyType="Binary"/>
        </t:AdditionalProperties>
      </ItemShape>
      <ItemIds>
        <t:ItemId
Id="AQAbAHRlc3Rkb21AYWxleGNoMjAwADcuYWw2NC5jb20ARgAAA1H9bvIF4HJKp52BLKV2tAYHAPCW3xic6cNDvJShVPo
+lQAABEcAAADwlt8YnOnDQ7yUoVT6PpUAAAByqWGc9AAAAA=="
ChangeKey="DwAAABYAAADwlt8YnOnDQ7yUoVT6PpUAAHKpYfzx" />
      </ItemIds>
    </GetItem>
  </soap:Body>
</soap:Envelope>

Changing the BaseShape propertie to 'Default', 'AllProperties' or
'IdOnly' has no effect on the result.

It really seems that there is a matter to get the custom properties
with GetItem method.....

Dom.
date: Wed, 07 Nov 2007 02:11:43 -0800   author:   Dom

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
The following works okay for me to retrieve a custom property which is a 
string


<?xml version="1.0" encoding="utf-8"?><soap:Envelope 
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><GetItem 
xmlns="http://schemas.microsoft.com/exchange/services/2006/messages"><ItemShape><BaseShape 
xmlns="http://schemas.microsoft.com/exchange/services/2006/types">AllProperties</BaseShape><AdditionalProperties 
xmlns="http://schemas.microsoft.com/exchange/services/2006/types"><ExtendedFieldURI 
DistinguishedPropertySetId="PublicStrings" PropertyName="MycustomProp" 
PropertyType="String" /></AdditionalProperties></ItemShape><ItemIds><ItemId 
Id="AAAm=" ChangeKey="DwAAACREmDP" 
xmlns="http://schemas.microsoft.com/exchange/services/2006/types" 
/></ItemIds></GetItem></soap:Body></soap:Envelope>

proxy Code


                        PathToExtendedFieldType epExPath1 = new 
PathToExtendedFieldType();
                        epExPath1.DistinguishedPropertySetId = 
DistinguishedPropertySetType.PublicStrings;
                        epExPath1.DistinguishedPropertySetIdSpecified = 
true;
                        epExPath1.PropertyName = "MycustomProp";
                        epExPath1.PropertyType = 
MapiPropertyTypeType.String;

                        GetItemType giRequest = new GetItemType();
                        ItemIdType iiItemId = new ItemIdType();
                        iiItemId.Id = miMailboxItem.ItemId.Id;
                        iiItemId.ChangeKey = miMailboxItem.ItemId.ChangeKey;
                        ItemResponseShapeType giResponseShape = new 
ItemResponseShapeType();
                        giResponseShape.BaseShape = 
DefaultShapeNamesType.AllProperties;
                        giResponseShape.IncludeMimeContent = true;
                        giRequest.ItemShape = giResponseShape;
                        giRequest.ItemShape.AdditionalProperties = new 
BasePathToElementType[1];
                        giRequest.ItemShape.AdditionalProperties[0] = 
epExPath1;
                        giRequest.ItemIds = new ItemIdType[1];
                        giRequest.ItemIds[0] = iiItemId;
                        giRequest.ItemShape.BaseShape = 
DefaultShapeNamesType.AllProperties;

                        GetItemResponseType giResponse = 
esb.GetItem(giRequest);
                        if 
(giResponse.ResponseMessages.Items[0].ResponseClass ==
                        ResponseClassType.Error)
                        {
                            Console.WriteLine("Error Occured");
                            Console.WriteLine(giResponse.ResponseMessages.Items[0].MessageText);
                        }
                        else
                        {
                            ItemInfoResponseMessageType rmResponseMessage =
                            giResponse.ResponseMessages.Items[0] as 
ItemInfoResponseMessageType;
                            CalendarItemType ciCalentry = 
(CalendarItemType)rmResponseMessage.Items.Items[0];
                            Console.WriteLine(ciCalentry.ExtendedProperty[0].Item.ToString());
                        }


Cheers
Glen'

"Dom"  wrote in message 
news:1194430303.872206.187400@57g2000hsv.googlegroups.com...
> Here is the full XML of my request:
>
> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>               xmlns:xsd="http://www.w3.org/2001/XMLSchema"
>               xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
>               xmlns:t="http://schemas.microsoft.com/exchange/services/
> 2006/types">
>  <soap:Body>
>    <GetItem xmlns="http://schemas.microsoft.com/exchange/services/
> 2006/messages">
>      <ItemShape>
>        <t:BaseShape>AllProperties</t:BaseShape>
>        <t:AdditionalProperties>
>           <t:ExtendedFieldURI
> PropertySetId="6ED8DA90-450B-101B-98DA-00AA003F1305"
> PropertyName="Gid23" PropertyType="Binary"/> <!-- first try -->
>           <t:ExtendedFieldURI
> DistinguishedPropertySetId="PublicStrings" PropertyName="Gid23"
> PropertyType="Binary"/>
>           <t:ExtendedFieldURI
> DistinguishedPropertySetId="PublicStrings"
> PropertyName="cleanglobalobjid" PropertyType="Binary"/>
>           <t:ExtendedFieldURI
> DistinguishedPropertySetId="PublicStrings" PropertyName="global_objid"
> PropertyType="Binary"/>
>           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
> C000-000000000046" PropertyName="cleanglobalobjid"
> PropertyType="Binary"/>
>           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
> C000-000000000046" PropertyName="global_objid" PropertyType="Binary"/>
>           <t:ExtendedFieldURI PropertySetId="00020329-0000-0000-
> C000-000000000046" PropertyName="Gid23" PropertyType="Binary"/>
>        </t:AdditionalProperties>
>      </ItemShape>
>      <ItemIds>
>        <t:ItemId
> Id="AQAbAHRlc3Rkb21AYWxleGNoMjAwADcuYWw2NC5jb20ARgAAA1H9bvIF4HJKp52BLKV2tAYHAPCW3xic6cNDvJShVPo
> +lQAABEcAAADwlt8YnOnDQ7yUoVT6PpUAAAByqWGc9AAAAA=="
> ChangeKey="DwAAABYAAADwlt8YnOnDQ7yUoVT6PpUAAHKpYfzx" />
>      </ItemIds>
>    </GetItem>
>  </soap:Body>
> </soap:Envelope>
>
> Changing the BaseShape propertie to 'Default', 'AllProperties' or
> 'IdOnly' has no effect on the result.
>
> It really seems that there is a matter to get the custom properties
> with GetItem method.....
>
> Dom.
>
>
date: Thu, 8 Nov 2007 12:51:35 +1100   author:   Glen Scales [MVP]

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
Your XML works ok for me too, i can retrieve a custom propertie that i
had created with the UpdateItem xml for example.

Maybe i'm wrong when i use 'PublicStrings' to access the propertie i
want to retrieve: the Global Object Id.

Does this propertie belongs to the 'PublicStrings' namespace ? if so,
what's her name ?
And if not, how can it be retrived with ews ?

Thanks,

Dom.
date: Thu, 08 Nov 2007 00:07:42 -0800   author:   Dom

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
Hi,

the global object id (when referring tot the calendar item global object id) 
lives in another namespace.

Property-ID: 0x3
PropertySet: DistinguishedPropertySetType.Meeting

Kind regards,
Henning Krause

"Dom"  wrote in message 
news:1194509262.681696.177450@19g2000hsx.googlegroups.com...
> Your XML works ok for me too, i can retrieve a custom propertie that i
> had created with the UpdateItem xml for example.
>
> Maybe i'm wrong when i use 'PublicStrings' to access the propertie i
> want to retrieve: the Global Object Id.
>
> Does this propertie belongs to the 'PublicStrings' namespace ? if so,
> what's her name ?
> And if not, how can it be retrived with ews ?
>
> Thanks,
>
> Dom.
>
date: Thu, 8 Nov 2007 11:02:49 +0100   author:   Henning Krause [MVP - Exchange]

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
Thank you very much Henning, it's exactly what i was looking for, and
my request works fine now !!
(thanks Glen too)

An ultimate question: how did you do to find this answer ? in other
words, is there a way to know the EWS namespaces corresponding to the
other properties ?

Thanks a lot,

Dom.
date: Thu, 08 Nov 2007 06:27:58 -0800   author:   Dom

Re: using ExtendedFieldURI to retrive calendar customs properties between 0x8000 and 0xFFFE   
Hi Dom,

those are just MAPI properties which have been around for years.

In Exchange 2003, the notation was different, but the identifiers were the 
same.

Kind regards,
Henning Krause

"Dom"  wrote in message 
news:1194532078.873813.191900@v29g2000prd.googlegroups.com...
> Thank you very much Henning, it's exactly what i was looking for, and
> my request works fine now !!
> (thanks Glen too)
>
> An ultimate question: how did you do to find this answer ? in other
> words, is there a way to know the EWS namespaces corresponding to the
> other properties ?
>
> Thanks a lot,
>
> Dom.
>
date: Thu, 8 Nov 2007 17:31:43 +0100   author:   Henning Krause [MVP - Exchange]

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us