Page 1 of 1

Generate a define for the property

Posted: Sat Oct 09, 2021 4:29 pm
by OlegKRS
Hi

I want to make a component that uses a property and for this property I ticked "Generate a define for the property". When compiled into C code, this property appears in quotation marks. How do I remove quotes when compiling to C code?

Re: Generate a define for the property

Posted: Sat Oct 09, 2021 4:37 pm
by kersing
The property type ‘line of text’ causes the quotes.

Re: Generate a define for the property

Posted: Mon Oct 11, 2021 4:15 pm
by BenR
Hello,

I've created a demo for you where I remove the quote marks using an Compile -> AddProperty event macro.

Event.jpg
Event.jpg (50.51 KiB) Viewed 2389 times
Hopefully it should do everything you need it to do.

PropertyDemo.fcfx
(10.05 KiB) Downloaded 140 times

Results in this being generated in the C code.

Code: Select all

#define MX_ENCODERKF_DEMO_0 portc

Re: Generate a define for the property

Posted: Mon Oct 11, 2021 7:07 pm
by OlegKRS
Hello,

Many thanks BenR.