Var Engines, Nodes, Node, Field: the Variant;//the node and the domain variables,
I: integer;//control loop variables, to assembly assignment,
The begin
Nodes:=Engine. RootNodes;//when clicking on a part on a part of color disappears, access to a node set,
BCB
The Variant Engine, Nodes, Node, Field;//the node and the domain variables,
int i;//control loop variables, to assembly assignment,
Int j;
Nodes=Engine - & gt; RootNodes;
Consult Delphi under normal operation, and is an error in the BCB, what reason is this? The problem of the Variant?
CodePudding user response:
In the ". "in the Delphi is not entirely and BCB" - & gt;" Equal,The compiler of the former more powerful, so can be used as access to the members of the variant of wording,
But because to be compatible with c + + syntax BCB, "- & gt;" The left side of the operator must be a pointer, the right is a member of the pointer object,
(that is, the variable name on the left, the statement is the Form *, specific look at c + + syntax)
It is obvious that the Variant variables is not a pointer, so "- & gt;" Operators must be ungrammatical,
You need to look at BCB of Variant types of grammar guide operation,,, I will not write the BCB ~ N years
CodePudding user response:
Well well, what you said is right, but I change, but prompt RootNodes is not a member of the variant.If the Variant of Delphi in BCB will be replaced by a new data type?