Hi, I tried adding the following script in my DocumentDefinition in the Administrator Station.


if (Context.Field("ReceiptType").Text==" Diesel "){ 

        Context.Field("Type").Text = " Gas Station ";



catch (System.FormatException ex){

     Context.CheckSucceeded = false;

     Context.FocusedField= Context.Field(" ReceiptType ");

     Context.ErrorMessage="Unexpected error while checking value for field " + Context.Field(" ReceiptType ").Name;



The I for the Script was: If the Engine matches the word Diesel on an Image it writes Gas Station in an empty Type Field.

But it failed regardless if the script is correct, it shows the error:


Script:System.Runtimte.InteropServices.COMExcpetion(0x8004005): No field with name 'ReceiptType'. at ABBYY.FlexiCapture.IRuleContext.Field(String Name) at Main.Execute(IRuleContext Context)

I hope someone can help me solve this since I'm new to scripting in the Administrator Station.