Page 1 of 1

Jiwa Grid Passwords Column

PostPosted: Fri Dec 11, 2020 5:12 pm
by SBarnes
Is there a way and if so how to make a column behave as a password field in the Jiwa Grid namely in that it show dots or **** for the password until you edit it?

Re: Jiwa Grid Passwords Column  Topic is solved

PostPosted: Fri Dec 11, 2020 8:41 pm
by nsbandara
Hi Stuart,

You can use TextCellType with PasswordChar.

Please see code example below that adds Document Password column to debtor documents grid.

Code: Select all
#region "FormPlugin"
public class FormPlugin : System.MarshalByRefObject, JiwaFinancials.Jiwa.JiwaApplication.IJiwaFormPlugin
{

    public override object InitializeLifetimeService()
    {
        // returning null here will prevent the lease manager
        // from deleting the Object.
        return null;
    }

    public void SetupBeforeHandlers(JiwaFinancials.Jiwa.JiwaApplication.IJiwaForm JiwaForm, JiwaFinancials.Jiwa.JiwaApplication.Plugin.Plugin Plugin)
    {
    }

    public void Setup(JiwaFinancials.Jiwa.JiwaApplication.IJiwaForm JiwaForm, JiwaFinancials.Jiwa.JiwaApplication.Plugin.Plugin Plugin)
    {
      if (JiwaForm is JiwaFinancials.Jiwa.JiwaDebtorsUI.frmDebtor)
        {
            JiwaFinancials.Jiwa.JiwaDebtorsUI.frmDebtor frmDebtor = JiwaForm as JiwaFinancials.Jiwa.JiwaDebtorsUI.frmDebtor;
         
            frmDebtor.DocumentsGrid.AddColumn("Document Password", new FarPoint.Win.Spread.CellType.TextCellType() { PasswordChar = '*' }, "Document Password", 8, false, true, true, false, 255, false, false, 0, false);

        }
    }
}
#endregion