A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Add-ins for Outlook
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Problems while adding new Category in Outlook 2007



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old September 10th 06, 01:46 PM posted to microsoft.public.outlook.program_addins
Ahmed Al-Lakani
external usenet poster
 
Posts: 2
Default Problems while adding new Category in Outlook 2007

I got a problem in my outlook add-in developed by C++,
While adding new category, I’m trying to add a new Category so I can later
on assign it to my newly created appointment,

My Code as the following

Outlook::Categories *pCats = NULL;
Outlook::Category *pCat = NULL;
HRESULT hRes = E_FAIL;


if(m_pNameSpace != NULL)
{
// get list of categoreies
hRes = m_pNameSpace-get_Categories(&pCats);

if(hRes == S_OK && pCats != NULL)
{
hRes = pCats-Add(BSTR("my new Category"), Outlook:lCategoryColorBlue,
Outlook:lCategoryShortcutKeyNone , &pCat);
}
}

  #2  
Old September 10th 06, 01:55 PM posted to microsoft.public.outlook.program_addins
Ahmed Al-Lakani
external usenet poster
 
Posts: 2
Default Problems while adding new Category in Outlook 2007

Sorry, i didn't write the rest of the problem
While pCats-Add been called, it throws an exception,
The exception error message is

“Run-Time Check Failure #0 - The value of ESP was not properly saved across
a function call. This is usually a result of calling a function declared
with one calling convention with a function pointer declared with a different
calling convention.”

Could any body help


"Ahmed Al-Lakani" wrote:

I got a problem in my outlook add-in developed by C++,
While adding new category, I’m trying to add a new Category so I can later
on assign it to my newly created appointment,

My Code as the following

Outlook::Categories *pCats = NULL;
Outlook::Category *pCat = NULL;
HRESULT hRes = E_FAIL;


if(m_pNameSpace != NULL)
{
// get list of categoreies
hRes = m_pNameSpace-get_Categories(&pCats);

if(hRes == S_OK && pCats != NULL)
{
hRes = pCats-Add(BSTR("my new Category"), Outlook:lCategoryColorBlue,
Outlook:lCategoryShortcutKeyNone , &pCat);
}
}

 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
redering problems outlook 2007 ldm2331 Outlook - General Queries 5 September 5th 06 09:14 PM
Having problems adding ACT! address book to Outlook 2003 vince Outlook - Using Contacts 0 July 6th 06 09:11 PM
Problems with new outlook 2007 [email protected] Outlook - General Queries 2 May 31st 06 10:44 AM
Outlook 2007 problems BillR [MVP] Outlook - Installation 1 May 26th 06 10:32 AM
Category problems Judy Outlook - Using Contacts 0 April 6th 06 10:47 PM


All times are GMT +1. The time now is 03:33 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright 2004-2025 Outlook Banter.
The comments are property of their posters.