Skip to content

Problem assigning string to a TOvcPictureField with a PictureMask #42

Description

@MauriceI

Hi,

I've run into a problem when using a TOvcPictureField with a PictureMask.

In a simple test case I have a form with a single TOvcPictureField. It has a PictureMask of AA-99-9999-999 and all the other properties are left to their default. When I try to set the value to VH-88-8888-888 using the code below the field end up with a value of VH--8-8-88-88-

OvcPictureField1.AsString := 'VH-88-8888-888';

I was able to trace the issue to commit c0c2e3e. In it change, the check to strip mask characters from the input string before merging it with the mask was changed so it no longer includes strings which are the same length as the mask which is the case in this scenario.

Before changing it back I would like to understand the logic behind why this was changes and for which scenario it applies.

Thanks for your help!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions