Code for logging Job Creation Date

If you set up a BAM to monitor the field JobHead.JobNum, you can create an alert program to run when the BAM fires that stores the creation date in one of the user-defined fields. Example is below:

{ud/GlbAlert.i &TableName = "JobHead"}

SENDMAIL = false.

IF OLDjobhead.jobnum = ""
AND OLDjobhead.jobnum NE jobhead.jobnum THEN
RUN lib/UpdateTableBuffer.r(input BUFFER jobhead:HANDLE, 'DATE01', TODAY).

RETURN

This will set JobHead.Date01 to the current date when the job is created. It checks the buffer to see if the jobnum was blank and was then set to a value. It only fires when the jobnum is changed from blank to a value, so it won't fire every time the job is updated.

There are other ways to do this, but I am not too familiar with BPM's or .net coding.

--- In vantage@yahoogroups.com, "mahsangilbert" <tgilbert@...> wrote:
>
> I know that Vantage doesn't have a field for "Job Creation Date," and I'm not interested in using the Change Log for this.
>
> I would imagine that I could use code to dump the Job Creation Date into a custom field, correct? If so, are there any Progress Code Experts out there who could help me with this?
>
> Thanks in advance,
>
> Todd Gilbert
> Global Contract Manufacturing, Inc.
> Vantage 6.1
>
I know that Vantage doesn't have a field for "Job Creation Date," and I'm not interested in using the Change Log for this.

I would imagine that I could use code to dump the Job Creation Date into a custom field, correct? If so, are there any Progress Code Experts out there who could help me with this?

Thanks in advance,

Todd Gilbert
Global Contract Manufacturing, Inc.
Vantage 6.1