<div dir="ltr">Hello,<div><br></div><div>Last week, a member of Lazarus Brazillian group reported a problem related to the MaskUtils unit. His message (adapted from pt-BR to en-US) was:</div><div><br></div><div><i>"Good afternoon.</i></div><div><i><br></i></div><div><i>I need help with FormatMaskText, because it doesn't work properly with the same code that works fine on Delphi".</i></div><div><br></div><div>His refactored example was:</div><div><br></div><div>=== code ===</div><div><br></div><div><div>uses maskutils;<br></div><div><br></div><div>const MY_UNMASKED_VALUE = 'H1H357K808K44616YK8720';</div><div><br></div><div>begin</div><div> WriteLn(FormatMaskText('!>cccccc\-ccccc\-ccccc-cccccc;0;*', MY_UNMASKED_VALUE));</div><div> // uncomment the like below and enjoy the crash</div><div> //WriteLn(FormatMaskText('!>CCCCCC\-CCCCC\-CCCCC-CCCCCC;0;_', MY_UNMASKED_VALUE));</div><div>end.</div></div><div><br></div><div>=== /code ===</div><div><br></div><div>The expected value: H1H357-K808K-44616-YK8720.</div><div><br></div><div>The returned value: H1H357-K808K-44616-******.<br></div><div><br></div><div>If you uncomment the code in the last writeln, it will raise the generic "FormatMaskText function failed!" error.</div><div><br></div><div>However, this attached patch was sent from another member and it seems fix the problem.</div><div><br></div><div>Can I open an issue at bugtracker related to this problem?</div><div><br></div><div>Thank you!</div><div><div><br></div>-- <br><div><div dir="ltr"><div>Silvio Clécio</div></div></div>
</div></div>