Please use Insert > Insert Code (switch to rich formatting to view this option) to paste source code. It uses single line spacing, provides line numbering, make code easier to copy and so on. This is the result:
public void modifiedField(FieldId _fieldId)
{
FloorMaster floorMaster;
super(_fieldId);
switch(_fieldId)
{
case fieldNum(CubicalMaster,FloorId):
this.FloorDescription = floorMaster.Description;
break;
default:
break;
}
}
If you debugged your code, you would have found that this.FloorDescription is empty because you assign an empty value to it. (As you see, the debugger can give you a lot of important information - make sure you use it.)
The reason is in the fact that you never assigned anything to floorMater variable, therefore it has all fields empty. What you need to do is finding the FloorMaster record for the given FloorId. For example:
public void modifiedField(FieldId _fieldId)
{
super(_fieldId);
switch(_fieldId)
{
case fieldNum(CubicalMaster, FloorId):
FloorMaster floorMaster = FloorMaster::find(this.FloorId);
this.FloorDescription = floorMaster.Description;
break;
}
}
If FloorMaster doesn't have find() method, go and add it. You can find a plenty of examples in existing tables, but if you struggle with it anyway, feel free to ask.
public void modifiedField(FieldId _fieldId)
{
FloorMaster floorMaster;
super(_fieldId);
switch(_fieldId)
{
case fieldNum(CubicalMaster, FloorId):
floorMaster = FloorMaster::find(this.FloorId);
this.FloorDescription = floorMaster.Description;
break;
}
}