Call the CTRecord.IsVariableField() method to check if a field is variable length or not. CTRecord.IsVariableField() returns true if the field is variable length.
// check if field 0 is variable length
if (ARecord.IsVariableField(0))
{
Console.Write("Field 0 is variable length\n");
}
else
{
Console.Write("Field 0 is fixed length\n");
}