# How i can to compare two TCHAR in C++?

**URL:** <https://forums.unrealengine.com/t/how-i-can-to-compare-two-tchar-in-c/486044>\
**Category:** C++\
**Tags:** fstring, compare, unreal-engine, Array, CPP, question\
**Created:** [July 11, 2021, 10:05am UTC](https://forums.unrealengine.com/t/how-i-can-to-compare-two-tchar-in-c/486044 "2021-07-11T10:05:52Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![VladAnt\_1995](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@VladAnt\_1995](https://forums.unrealengine.com/u/VladAnt_1995)\
**Post date:** [July 11, 2021, 10:05am UTC](https://forums.unrealengine.com/t/how-i-can-to-compare-two-tchar-in-c/486044/1 "2021-07-11T10:05:52Z")

</div>

Hallo! i’ve some FString, and i get from it TCHAR by index. How i can compare it with other TCHAR?

```
FString str = "Hallo my little World";

 bool getCh(int x, TCHAR ch) {
	return (FCString::Strcmp(&str[x], ch)!=0);
 }

```

And in other script i call method getCh(…) something like this “getCh(1, ‘q’)” hoping to get true or false. BUT THIS DON’T WORK! ;-(
