procedure TMapForm.UnBound1Click(Sender: TObject);
var
flds: variant;
ds: variant;
unusedParam: OleVariant;
begin
TVarData(unusedParam).vType := varError;
TVarData(unusedParam).vError := DISP_E_PARAMNOTFOUND;
{Create the Fields object and then
add Fields for unbound dataset
´´½¨×ֶζÔÏ󣬲¢Ôö¼Ó×ֶθøδ°ó¶¨Êý¾Ý¼¯}
flds := CreateOleObject('MapX.Fields.4');
flds.add('State', 'State', miAggregationIndividual, miTypeString);
flds.add('Pop80', 'Pop80', miAggregationSum, miTypeNumeric);
flds.add('Pop90', 'Pop90', miAggregationSum, miTypeNumeric);
{Add a dataset passing in the Fields object}
ds := map1.datasets.add(miDatasetUnbound, unusedParam, unusedParam, 'State', unusedParam, 'USA', flds, unusedParam);
{Add an Individual Theme}
ds.Themes.Add(miThemeIndividualValue, 'State', 'StateByState');
UnBound1.Enabled := False;
end;
请问TVarData实现什麽功能?
unusedParam: OleVariant 这是什么意思?怎么用?
DISP_E_PARAMNOTFOUND 这是什么意思?怎么用?