title: How to reference customer field which I created in AP301000
body: <p>I have created a customer field on AP301000. The field works fine on screen. now I want this field to be populated after Vendor was selected, so I tried to customize business logic with code list this:</p>
  
  <pre><code> protected void APInvoice_VendorID_FieldUpdated(PXCache cache, PXFieldUpdatedEventArgs e, PXFieldUpdated InvokeBaseHandler)
      {
        if(InvokeBaseHandler != null)
          InvokeBaseHandler(cache, e);
        var row = (APInvoice)e.Row;
  
        APInvoice.UsrVendorKey="test";
      }
  </code></pre>
  
  <p>but I got the following error:</p>
  
  <pre><code>'PX.Objects.AP.APInvoice' does not contain a definition for 'UsrVendorKey' in file : Code#APInvoiceEntry(56)
  </code></pre>