G
Guest
hi all,
i have an app that exports excel graphs using "#import excel.h" directive,
now i'm converting the app to use a automation class generated by Microsoft
Studio 6.0 Class Wizard( that has all modules/properties ).
I'm having some trouble converting the line:
series->Fill->OneColorGradient( Office::msoGradientHorizontal, 4, 0.25 );
i have converted to:
#define CovOptionalParam COleVariant((long)DISP_E_PARAMNOTFOUND, VT_ERROR)
SeriesCollection series_collection =
wrkChart.SeriesCollection(CovOptionalParam);
int nSeries = series_collection.GetCount();
for( int iSeries=0; iSeries<nSeries; ++iSeries )
{
Series series_obj = series_collection.Item( _variant_t((short)(iSeries +
1)) );
FillFormat fill_format = series.GetFill();
fill_format.OneColorGradient( msoGradientHorizontal, 4, 0.25 );
}
but it does not work an exception is raised, any ideas?
thanks for all the help
Jose Valente
i have an app that exports excel graphs using "#import excel.h" directive,
now i'm converting the app to use a automation class generated by Microsoft
Studio 6.0 Class Wizard( that has all modules/properties ).
I'm having some trouble converting the line:
series->Fill->OneColorGradient( Office::msoGradientHorizontal, 4, 0.25 );
i have converted to:
#define CovOptionalParam COleVariant((long)DISP_E_PARAMNOTFOUND, VT_ERROR)
SeriesCollection series_collection =
wrkChart.SeriesCollection(CovOptionalParam);
int nSeries = series_collection.GetCount();
for( int iSeries=0; iSeries<nSeries; ++iSeries )
{
Series series_obj = series_collection.Item( _variant_t((short)(iSeries +
1)) );
FillFormat fill_format = series.GetFill();
fill_format.OneColorGradient( msoGradientHorizontal, 4, 0.25 );
}
but it does not work an exception is raised, any ideas?
thanks for all the help
Jose Valente