some troubles with including sdk

Jun 26, 2012 at 10:59 AM

Hi everyone. I only started use pst sdk and have some troubles.

I use simple test project, and added the path to sdk and boots in property of project. And when i building the solution i had next problems.

<code>

#include <pst.h>
#include <iostream>
#include <iterator>
#include <algorithm>

int main()
{
    pst myfile(L"mybackup.pst");

    return 1;
}

</code>

 

<troubles>

Error    1    error C2065: 'pst' : undeclared identifier    d:\developer\visual c++\test\test\test.cpp    8
Error    2    error C2146: syntax error : missing ';' before identifier 'myfile'    d:\developer\visual c++\test\test\test.cpp    8
Error    3    error C3861: 'myfile': identifier not found    d:\developer\visual c++\test\test\test.cpp    8
    4    IntelliSense: static assertion failed with "header<ulonglong> dwCRCFull at incorrect offset"    c:\usr\pst file format sdk\pstsdk\pstsdk\disk\disk.h    208
    5    IntelliSense: identifier "pst" is undefined    d:\developer\visual c++\test\test\test.cpp    8

</troubles>

 

how can i resolve it?

Jun 26, 2012 at 2:03 PM

pst is defined in namespace pstsdk:

namespace pstsdk
{
class pst : private boost::noncopyable {...

Change to:

pstsdk::pst myfile(L"mybackup.pst");