Trouble Renaming components
Hi all.
I am a little confused. I added a report to a form and started designing
it. I realised I had some fields that would need populating through code so
I used TppLabels rather than TppDBText for the fields concerned and renamed
them in the DADE so that I could easily refer to them in code. But when I
return to Delphi's IDE all the components still have their original names
e.g. ppLabel32. Why is this as it makes it near impossible to populate a
field's value through delphi code. Yes I know there is RAP, but in this
case I want to do the work in a standard delphi function. Any ideas?
TIA.
John.
I am a little confused. I added a report to a form and started designing
it. I realised I had some fields that would need populating through code so
I used TppLabels rather than TppDBText for the fields concerned and renamed
them in the DADE so that I could easily refer to them in code. But when I
return to Delphi's IDE all the components still have their original names
e.g. ppLabel32. Why is this as it makes it near impossible to populate a
field's value through delphi code. Yes I know there is RAP, but in this
case I want to do the work in a standard delphi function. Any ideas?
TIA.
John.
This discussion has been closed.
Comments
through the object inspector. I'm not able to reproduce this behavior in D6
and RB 6.03. What version of Delphi/RB are you using? What steps can I
take to reproduce this?
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com
Forgot to add Delphi 5 and RB 6.02.
component.
The Report Tree is behaving as designed. It is intended for end users to be
able to "appear" to change the names of the report components. It doesn't
change the actual component name because this would break any code
associated with that report component at runtime if the end user changes its
name. Also, in RAP, we use the UserName instead of Name to identify the
different components.
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com
be
its
Thanks Jim. I understand how it works now.
Cheers.
John.