B2026-053-Find-Unlinked-Values-of-Selected

This commit is contained in:
2026-07-24 10:47:25 -04:00
parent f93b16fc52
commit 2261c8f0f5
+16 -2
View File
@@ -2199,7 +2199,7 @@ namespace Volian.Controls.Library
if (match.Success) // Special case for percents.
{
int sl = SearchString.Length;
int precentIdx = SearchString.IndexOf('%');
int precentIdx = SearchString.LastIndexOf('%');
int startIndex = 0;
if (sl == precentIdx + 1) // % the last char.
{
@@ -2207,14 +2207,28 @@ namespace Volian.Controls.Library
var isNumeric = int.TryParse(ss, out int n);
if (isNumeric == true) // B2026-053 other that a % are the rest of the characters numbers.
{
ss = ' ' + SearchString; //B2026-053 add a space prefix to make the search exact. If search is 5% this makes it excult 25% 55% etc.;
ss = ' ' + SearchString + ' '; // to get exact match add spaces before and after search string.
}
else
{
ss = ' ' + SearchString + ' '; // string it not a percent.
}
}
else
{
int strl2 = SearchString.Length;
int prcIdx2 = SearchString.LastIndexOf(' ');
int strIdx2 = 0;
if (strl2 == prcIdx2 + 1) // if the last char is ' ' the last char.
{
ss = ' ' + SearchString; //B2026-053 add a space prefix to make the search exact. If search is 5% this makes it excult 25% 55% etc.;
}
else
{
ss = ' ' + SearchString + ' '; // Exact match add spaces before and after search string.
}
}
}
else
{
ss = ' ' + SearchString + ' '; // Exact match add spaces before and after search string.