vIndex=long(0);
m_datagrid.GetColumns.GetItem(vIndex).SetWidth(10);
vIndex=long(1);
m_datagrid.GetColumns.GetItem(vIndex).SetWidth(20);
出错:
:\king22\MFC\SQL\SQLDlg.cpp(128) : error C2664: 'GetItem' : cannot convert parameter 1 from 'class _variant_t' to 'int'
        Ambiguous user-defined-conversion
F:\king22\MFC\SQL\SQLDlg.cpp(128) : error C2228: left of '.SetWidth' must have class/struct/union type
F:\king22\MFC\SQL\SQLDlg.cpp(130) : error C2228: left of '.GetItem' must have class/struct/union type
F:\king22\MFC\SQL\SQLDlg.cpp(130) : error C2228: left of '.SetWidth' must have class/struct/union type
Error executing cl.exe.SQL.exe - 4 error(s), 0 warning(s)
已经定义了GETITEM()函数,请问是那里出错?