ATL Provider Error ATL2023
TOC
Collapse the table of content
Expand the table of content
The document is archived and information here might be outdated

ATL Provider Error ATL2023

Attribute should be used with a real array with storage backing it and not just a simple pointer.

The following sample generates ATL2023.

// ATL2023.cpp
// compile with: /c
// ATL2023 expected
#define _ATL_ATTRIBUTES
#include <atlbase.h>
#include <atlcom.h>

class CATL2023
{
   public :
   [ rdx ("HKLM", "test", "text") ] TCHAR *m_szValue;
// to resolve, change the preceding line to
// [ rdx ("HKLM", "test", "text") ] TCHAR m_szValue[100];
};
Show:
© 2016 Microsoft