Board index » cppbuilder » W8066 Unreachable code
standus
![]() CBuilder Developer |
standus
![]() CBuilder Developer |
W8066 Unreachable code2005-03-20 07:25:14 PM cppbuilder48 Hi, I have a problem with using some API functions for Outlook Express. here is short example: Unit1.cpp is at: www.uncledelacruz.net/down/Unit1.cpp Unit1.h is at: www.uncledelacruz.net/down/Unit1.h and msoeapi.h is at: www.uncledelacruz.net/down/msoeapi.h Problem is that I got warning: W8066 Unreachable code on this line: props.cbSize = sizeof(FOLDERPROPS); Whats the problem please? Please help. standus |
standus
![]() CBuilder Developer |
2005-03-20 07:33:40 PM
Re:W8066 Unreachable code
Hi,
I have a problem with using some API functions for Outlook Express. here is short example: Unit1.cpp is at: www.uncledelacruz.net/down/Unit1.cpp Unit1.h is at: www.uncledelacruz.net/down/Unit1.h and msoeapi.h is at: www.uncledelacruz.net/down/msoeapi.h Problem is that I got warning: W8066 Unreachable code on this line: props.cbSize = sizeof(FOLDERPROPS); Whats the problem please? Please help. standus |
hgiese
![]() CBuilder Developer |
2005-03-20 08:10:07 PM
Re:W8066 Unreachable code
On 20 Mar 2005 03:33:40 -0800, "standus" < XXXX@XXXXX.COM >wrote:
Quote
Thus, this line is considered to be part of the 'if' AND it follows a 'return', so it can never be reached. Normally, this code shouldn't even compile because of the missing '}', but you have a second error: The next to last line of this function contains a superfluous '}', so that for the compiler all braces match. Nice way to shoot yourself in the foot :) HTH Helmut Giese {smallsort} |
Standus
![]() CBuilder Developer |
2005-03-21 03:48:22 AM
Re:W8066 Unreachable code
Yes It was the problem.
But in finaly it dos not work. So I rebuild it from begining and now its looking good except this error: [C++ Error] Unit1.cpp(70): E2451 Undefined symbol 'm_pStoreNamespace' All rebuilded files are in the same web location. I am using this source: www.codeproject.com/com/Outlook_Express_Messages.asp Thank for your help. Standus "Helmut Giese" < XXXX@XXXXX.COM >píše v diskusním příspěvku QuoteOn 20 Mar 2005 03:33:40 -0800, "standus" < XXXX@XXXXX.COM >wrote: |
hgiese
![]() CBuilder Developer |
2005-03-21 04:28:26 AM
Re:W8066 Unreachable code
On Sun, 20 Mar 2005 20:48:22 +0100, "Standus" < XXXX@XXXXX.COM >wrote:
QuoteYes It was the problem. - because of a typo Search in all your .h files for 'm_pStoreNamespace' (would be the definition of a struct or a class) and then #include this file. HTH Helmut Giese |
Ivan Johansen
![]() CBuilder Developer |
2005-03-21 04:28:39 AM
Re:W8066 Unreachable code
Standus wrote:
QuoteBut in finaly it dos not work. void TForm1::AddFolders(STOREFOLDERID dwFolderId) Ivan Johansen |
Standus
![]() CBuilder Developer |
2005-03-21 06:49:30 AM
Re:W8066 Unreachable code
Yes .... its working well.
Thank you very much Ivan. Stan "Ivan Johansen" < XXXX@XXXXX.COM >píse v diskusním príspevku QuoteStandus wrote: |