If you want to show custom columns in your applications job monitor there are several things to do.

  • At first you need to add the required coulmn to you applications engine database table TMBATCH. Please keep in mind that only STRING or INTEGER columns are supported. As a prefix PB_ for the coloumn name is required. E.g. PB_VENDORNAME. Please create the column name also in upper case letters.
  • After you added the new column(s) you also need to update the database views JMView and JobMonitor.
  • Now you can select the new column in the repository settings in content navigator. Iin my case the columns are called PB_NL and PB_KASSENTAG
Datacap Application configuration in Content Navigator repositories

Now comes the more difficult part. Because you cannot use existing SQL action from datacap to update these columns. If a task completes the batchpilot will overwrite the update columns with empty fields. The solution is to write a custom action to update the batchpilot information so that the information persists in the engine database.

I wrote a custom action in .NET. The following code function is used to update the Batchpilot

public bool UpdateJobMonitor(string column, string value)
        {

            dcSmart.SmartNav localSmartObj = new dcSmart.SmartNav(this);
            string input = localSmartObj.MetaWord(value);
            /// BatchPilot.set_XtraBatchFieldValue(column, input); ///
            DatacapRRBatchPilot.set_XtraBatchFieldValue(column, input);
            WriteLog("SmartNav: " + this);            
            WriteLog("TIMETOACT Setting Column: " + column + " To Value: " + input);
            
            return true;
        }

In the TheRRX.rrx file I added the following

<method name="UpdateJobMonitor">
      <p name="Spaltenname" type="string" qi="Der Name des Feldes aus dem gelesen wird.  Smart parameters are supported."/>
      <p name="Feldname" type="string" qi="Der name der Spalte die im JobMonitor geschrieben wird.  Smart parameters are supported."/>

      <ap>
        Updates the TMBATCH table with custom values for BatchPilot.
      </ap>
      <h>
        Eingabe von Spaltenname und Feldname<br/><br/>

        <e>
          <b>UpdateJobMonitor("PB_NIEDERLASSUNG,@P\Niederlassung")</b><br/>
          Smart Parameter erlaubt.
        </e>
      </h>
      <lvl>All levels.</lvl>
      <ret>
        <b>True,</b> if the action succeeds.  Otherwise, <b>False.</b>
      </ret>
    </method>

Here I read a fileds value and pass this as “input” variable to the action to update the batchpilot.

27 thoughts on “Creating a custom column in Job Monitor for IBM Datacap

  1. Hello would you mind letting me know which webhost you’re utilizing?
    I’ve loaded your blog in 3 different browsers and I must say this blog loads a lot
    quicker then most. Can you suggest a good hosting
    provider at a honest price? Cheers, I appreciate it!

  2. You can certainly see your enthusiasm within the paintings you write.

    The world hopes for even more passionate writers like you who
    are not afraid to mention how they believe. All the time follow
    your heart.

    my web-site; Straight Gains XL (James)

  3. We absolutely love your blog and find most of your
    post’s to be what precisely I’m looking for. Would you offer
    guest writers to write content available for you? I wouldn’t mind creating a post or elaborating on a number of the subjects you write in relation to here.
    Again, awesome blog!

    Also visit my blog … healthy skin

  4. Definitely believe that which you said. Your favorite reason seemed
    to be on the web the easiest thing to be aware of.
    I say to you, I certainly get annoyed while people consider worries that they just do not know
    about. You managed to hit the nail upon the top as well as
    defined out the whole thing without having side-effects ,
    people can take a signal. Will likely be back to get
    more. Thanks

    Also visit my webpage :: https://situstogelonline.co/

  5. Hey there! This is my 1st comment here so I just wanted to give a quick shout out and
    say I genuinely enjoy reading your articles.

    Can you recommend any other blogs/websites/forums that deal with the
    same subjects? Thanks a lot!

  6. I think this is among the most important info for me. And i’m
    glad reading your article. But wanna remark on few general things,
    The website style is perfect, the articles is really excellent : D.
    Good job, cheers

  7. Excellent post. I used to be checking constantly this weblog and
    I’m impressed! Very useful information specifically the remaining phase :
    ) I handle such info much. I used to be seeking this particular information for a very long time.

    Thanks and good luck.

Comments are closed.