Page 1 of 1

Increase System Settings Size

PostPosted: Thu Oct 23, 2025 5:00 pm
by SBarnes
I have to create an integration with a system that uses an authorisation token that is 859 characters long, :o is there a way to increase the size of a system setting in terms of what the grid allows as the database field is big enough?

Re: Increase System Settings Size  Topic is solved

PostPosted: Thu Oct 23, 2025 5:23 pm
by Mike.Sheen
In the SystemSettingPlugin class of a plugin, use the FormatCell method to set the MaxLength property of the cell type, eg:

Code: Select all
public void FormatCell(JiwaFinancials.Jiwa.JiwaApplication.IJiwaBusinessLogic BusinessLogicHost, JiwaFinancials.Jiwa.JiwaApplication.Controls.JiwaGrid GridObject, JiwaFinancials.Jiwa.JiwaApplication.IJiwaForm FormObject, int Col, int Row, JiwaFinancials.Jiwa.JiwaApplication.SystemSettings.Setting SystemSetting)
{
   if (SystemSetting.IDKey == "SampleSetting")
   {         
      ((FarPoint.Win.Spread.CellType.TextCellType)GridObject.ActiveSheet.Cells[Row, Col].CellType).MaxLength = 1000;
   }      
}


This will set the max length of the Contents cell in the System Configuration form on a tab captioned the same as the name of the plugin the system setting was defined - NOT the plugin maintenance form where you define the system setting and can enter the Contents also, but you really shouldn't.

Re: Increase System Settings Size

PostPosted: Thu Oct 23, 2025 5:32 pm
by SBarnes
Thanks Mike.