Outlook 2007 Beta 2 and EntryID Futures?
HI,
Which version of WDS does Outlook 2007 use - I think the Office installer asks you to download a WDS and I wondered what version it was?
What's the roadmap for this, as in in there another point release of WDS planned for the retail launch of Office 2007?
Also, are there any more changes planned to the mailtem EntryId new encoding, or put another way, what's the best/recommended way of being able to display an Outlook Item once it is returned by the WDS API Query?
- David
http://www.taglocity.com
[631 byte] By [
DavidIng] at [2007-12-24]
Hi David,
I'll try to answer a couple of your questions and will follow-up on the third.
Office 2007 uses version 3.0 of WDS. Currently, 3.0 is in "very beta" status. What does "very beta" mean? Essentially, you will have no UI available if you install 3.0. A second beta version will be out before too long and it will include a UI. If you really value the use of WDS, I would hold off on installing the Office 2007 beta until the new WDS 3.0 beta is released. A number of the Microsoft dogfooders found this out the tough way.
As for the roadmap, when installing Office 2007, users with an existing copy of WDS (version < 3.0) are asked to upgrade to 3.0 and given the appropriate link. I don't believe that WDS 3.0 will be packaged with the Office 2007 software, but I'll check into it for you. Of course, what I find out is subject to change.
I'll have to check into the best way to display an Outlook item via the API. Am I correct in assuming that you want to use your own program to pull and display search results from WDS via the WDS API?
Thanks,
Paul Nystrom - MSFT
Thanks for the info so far Paul - I do understand this info is subject to change, but clues do help too :-)
Yes, for the Outlook Item via API - in that at the moment in WDS 2.5 and 2.6 I made some assumptions of how to query for terms and get back Outlook items (Store ID, EntryID etc).
These currently come back in the results as an encoded URL string in bits that changed format between 2.5 and 2.6 - my app has to work for either so I try to handle both ways.
What I wanted to check was, and had never asked, was what is actually the 'best or recommended' way to call this Query API and get the info you need to display an item using Outlook?
Is it possible to get back a complete 'mail://' URL for a search result row, for example?
I'm just trying to do less code that I know may change in 3.0 etc. so am looking for the most standard way...
- David
Okay David,
I'm back with the last installment of info. Unfortunately, the URL encoding through the MAPI interface will be changing some. Below is the current plan for 3.0
Paul Nystrom - MSFT
//
// convert the string rep to the eid for it
//
HRESULT CEntryId::FromString(LPCWSTR pszEntryId)
{
return FromByte(pszEntryId);
}
// converts for the eid to a byte representation of it
const WORD kwBaseOffset = 0xAC00; // Hangul char range (AC00-D7AF)
HRESULT CEntryId::FromByte(LPCWSTR pszEntryId)
{
HRESULT hr = S_OK;
FreeBuffer();
m_cBytes = 0;
// figure out the # of bytes needed
ULONG cBytes = wcslen(pszEntryId);
ATLASSERT(cBytes > 0);
// allocate needed buffer size
hr = AllocateBuffer(cBytes, &m_pEntryId, &m_fMapiAlloc);
if (SUCCEEDED(hr))
{
// now decode proper
LPBYTE pbDest = (LPBYTE) m_pEntryId;
for (ULONG i = 0; i < cBytes; i++)
{
*pbDest = pszEntryId
- kwBaseOffset;
pbDest++;
}
m_cBytes = cBytes;
}
return hr;
}
Hello,
Can anyone confirm if this is still true for WDS 3.0 Beta 2?
I thought I would ask before I started updating the code...
Answered my own question - the algorithm works fine for WDS 3.0 RTM. Here's the C# in case it helps anyone else:
// Example of 3.0 'System.ItemUrl' column for an indexed Outlook mapi:// type
// "mapi://{s-1-5-21-57989841-1606980848-682003330-1003}/mailbox - david ing($fbafc100)/x/sent items/?????blahdeblah"// The above field format would ideally be documented somewhere, pretty please? I'll guess that's my uac SID, followed by the store display name and hash. Not sure what the '/x/' is about either...
// Take the encoded Hangul range characters onwards, i.e. the /?????blahdeblah bits are the EntryID
static string EIDFromEncodedStringWDS30(string strEIDEncoded)
{
StringBuilder sbEID = new StringBuilder(strEIDEncoded.Length);
int Len = strEIDEncoded.Length;
for (int index = 0; index < Len; index++)
{
ulong offset = 0xAC00; // Hangul char range (AC00-D7AF)
ulong ulByte = (((ulong)strEIDEncoded[index]) & 0xffff) - offset; sbEID.AppendFormat("{0:X2}", (ulByte & 0x00ff));
}
return sbEID.ToString();}