# Squareline studio string comparison c code

**URL:** <http://forum.squareline.io/t/squareline-studio-string-comparison-c-code/1143>\
**Category:** Bugs\
**Created:** [April 17, 2023, 6:02am UTC](http://forum.squareline.io/t/squareline-studio-string-comparison-c-code/1143 "2023-04-17T06:02:12Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mattb351](http://forum.squareline.io/letter_avatar_proxy/v4/letter/m/fbc32d/32.png) [@mattb351](http://forum.squareline.io/u/mattb351)\
**Post date:** [April 17, 2023, 6:02am UTC](http://forum.squareline.io/t/squareline-studio-string-comparison-c-code/1143/1 "2023-04-17T06:02:12Z")

</div>

I’m getting the following generated in SLS 1.2.3

> > if(“1234567890/” == “”) lv\_textarea\_set\_accepted\_chars(ui\_DateTextArea, NULL);  
> > else lv\_textarea\_set\_accepted\_chars(ui\_DateTextArea, “1234567890/”);

is that a bug or a feature? I would normally use strcmp or even strncmp these days.

---

<div class="post-metadata">

**Author:** ![mattb351](http://forum.squareline.io/letter_avatar_proxy/v4/letter/m/fbc32d/32.png) [@mattb351](http://forum.squareline.io/u/mattb351)\
**Post date:** [April 19, 2023, 1:02am UTC](http://forum.squareline.io/t/squareline-studio-string-comparison-c-code/1143/2 "2023-04-19T01:02:12Z")

</div>

I guess I should explain further. My project is for Visual Studio 19 and that compiles OK as it can handle that string comparison, but I also point my embedded system at the code that is output and it will not compile that code.

---

<div class="post-metadata">

**Author:** ![kisvegabor](http://forum.squareline.io/user_avatar/forum.squareline.io/kisvegabor/32/537_2.png) [@kisvegabor](http://forum.squareline.io/u/kisvegabor)\
**Post date:** [April 23, 2023, 5:31pm UTC](http://forum.squareline.io/t/squareline-studio-string-comparison-c-code/1143/3 "2023-04-23T17:31:30Z")

</div>

Something like this shouldn’t be added to the exported code. We are looking into it.
