I am working with the qgis api c++ 2.8.2, my application is written in QT 4.5.3 / C++I had to create a vectorlayer in memory with attributes and features and export it to a shp file to import it in QGIS applicaiton
Sothe creation of the vectorLayer Works, it is based on the qgis python programmig cookbook page 56then I decide to add attributes and set featureHere is the code for the attributes :
QgsVectorDataProvider * lDataProvider = lVectorLayer->dataProvider();QDateTime MyTime;lVectorLayer->startEditing();// add attributeQList lMyAttribField;lMyAttribField
Sothe creation of the vectorLayer Works, it is based on the qgis python programmig cookbook page 56then I decide to add attributes and set featureHere is the code for the attributes :
QgsVectorDataProvider * lDataProvider = lVectorLayer->dataProvider();QDateTime MyTime;lVectorLayer->startEditing();// add attributeQList lMyAttribField;lMyAttribField