code: public BasePanel onForm(Record recordMain, int iDocMode, boolean bReadCurrentRecord, int iCommandOptions, Map<String,Object> properties)
      {
          boolean bLinkGridToQuery = false;
          if ((iCommandOptions & ScreenConstants.USE_NEW_WINDOW) == ScreenConstants.USE_NEW_WINDOW)
              bLinkGridToQuery = true;
          return this.onForm(recordMain, iDocMode, bReadCurrentRecord, iCommandOptions, bLinkGridToQuery, properties);
      }
docs: Create a data entry screen with this main record.
  (null means use this screen's main record)
  @param recordMain The main record for the new form.
  @param iDocMode The document type of the new form.
  @param bReadCurrentRecord Sync the new screen with my current record?
  @param bUseSameWindow Use the same window?
  @return true if successful.