We are building a new experience for our SmartBear Community.
This site is now read-only. You can still browse and search as usual. Learn More
This site is now read-only. You can still browse and search as usual. Learn More
Hi,
Not sure, what you are asking.
aqString.Compare("Energiezähler", "ENERGIEZÄHLER", false)
above line will return 0 if both values matched.
From TC docuement:
Integer value that indicates the comparison result. The following values are possible:
| Value | Meaning |
|---|---|
| -1 | The String1 is less than String2. |
| 0 | The String1 identical to String2. |
| 1 | The String1 is greater than String2. |
https://support.smartbear.com/testcomplete/docs/reference/program-objects/aqstring/compare.html
To be more precise, I get the Result 1, not 0.
When I remove the "Ä"/ "ä", there is the 0, as expected.
I have the following code (in JScript):
function test3() {
Log.Message(aqString.Compare('Energiezähler','ENERGIEZÄHLER', false));
}
And this is returning a 0 as expected. I'm running TC 12.30. I don't have 11.2 installed to verify. It's possible that better support for extended ASCII within the aqString object may be included in later versions. I'd suggest you send this query off to the support team directly.
I just copy pasted the aqString.Compare("Energiezähler", "ENERGIEZÄHLER", false) into my TestComplete, it is giving 0
Hm-m-m...
I thought that it might to have something related to the current locale... but...
TC11.31 with non-German locale and VBScript project:
iStatusId = aqString.Compare("Energiezähler", "ENERGIEZÄHLER", False)
returned zero.