Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
460
Text in Add New Record Row
posted

Hi,

I have a grid that allows for the user to add new records located at the top.  Two of the columns are titled "Description", "Type".  For a new user they at first do not now that they can add text to the empty cells.  Is it possible to have some Italic text that is kinda faded that reads "Add Description" or "Add Type" in the Add New Record Row?  Kinda like you see in some forms on the web.  Little visual clues for the user.

 

Thanks,

Bryan

Parents
No Data
Reply
  • 27093
    posted

    Hello Bryan,

     

    I have been looking into your requirement and have created a style for you which you can set to the specific Field’s Settings.EditorStyle property. The style uses a MultuDataTrigger to check if the Editro is actually in the AddNewRecord and if it’s Text property is empty and sets the NullText property along with some text decorations according to your requirement:

     

    <Style TargetType="{x:Type igEditors:XamTextEditor}">

        <Style.Triggers>

            <MultiDataTrigger>

                <MultiDataTrigger.Conditions >

                    <Condition Binding="{Binding RelativeSource={RelativeSource Mode=Self}, Path=Text}" Value="" />

                    <Condition Binding="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type igDP:DataRecordPresenter}}, Path=IsAddRecord}"  Value="True" />

                </MultiDataTrigger.Conditions>

                <MultiDataTrigger.Setters>

                    <Setter Property="NullText" Value="Add description" />

                    <Setter Property="FontStyle" Value="Italic" />

                    <Setter Property="Opacity" Value="0.4" />

                </MultiDataTrigger.Setters>

            </MultiDataTrigger>

        </Style.Triggers>

    </Style>

     

    Please let me know if this is what you were looking for and if I can further assist you on the matter.

     

    Sincerely,

    Petar Monov

    Developer Support Engineer

    Infragistics Bulgaria

    www.infragistics.com/support

     

     

Children