E-mail alert with detail

Thank you to all that helped on this!! Both of the statements
string(part.partdesc,"x(15)" and substring(part.partdesc,1,15) work to get
me what I needed in the e-mail.



Thanks again for the help!



Steve



-----Original Message-----
From: Carl Peterson [mailto:cpeterson@...]
Sent: November 19, 2008 4:52 PM
To: vantage@yahoogroups.com
Subject: RE: [Vantage] Re: E-mail alert with detail



Right and Left Trim Functions are based on a specific character like an * or
/ or | or whatever. It is not designed to parse a string based on a
specific number of characters like the Progress statement of substring. The
Progress string statement would work, too. String(part.partdesc,"x(15)")

From: vantage@yahoogroups <mailto:vantage%40yahoogroups.com> .com
[mailto:vantage@yahoogroups <mailto:vantage%40yahoogroups.com> .com] On
Behalf Of
Norman Hutchins
Sent: Wednesday, November 19, 2008 5:15 PM
To: vantage@yahoogroups <mailto:vantage%40yahoogroups.com> .com
Subject: [Vantage] Re: E-mail alert with detail

I'm not a progress programmer by any means. The .p program that I posted, I
created by taking a couple of example .p programs, edited and combined a
little. And some help from this group too.

I also bought a book, Progress OpenEdge Development: Progress 4GL Handbook
by John Sadd (ISBN 0-923562-04-4) which I see is available online
(http://www.psdn
<http://www.psdn.com/library/servlet/KbServlet/download/1142-102-953/dvhbk.p
> com/library/servlet/KbServlet/download/1142-102-953/dvhbk.p
df)

In that book there are three trim functions: (pages 2-22 to 2-23)

Function: LEFT-TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from the beginning of the string. The trim-chars argument is optional and
defaults to all white space (spaces, tabs, carriage returns, and line
feeds).

Function: RIGHT-TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from the end of the string. The trim-chars argument is optional and
defaults to all white space.

Function: TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from both the beginning and the end of the string. The trim-chars argument
is optional and defaults to all white space.

Hope this helps, maybe someone else out there will be able to give you an
example of the syntax.

Norman Hutchins

Network Administrator

Howell Laboratories, Inc.

[Non-text portions of this message have been removed]


[Non-text portions of this message have been removed]





[Non-text portions of this message have been removed]
Hi,
In Vantage 8.03.404, I have tried to send alert message for 'shipped not invoiced' which is as follows,
1. In Business Activity Manager, I select the table name called ShipHead, Under table ShipHead I select the fields such as Invoiced, ShipStatus, ShipDate.
2. In Actions Tab, I check send alert check box and I gave email address, label, alert text, To address.
3. In Rules tab, i create a rule such as " for alert ( shipdate< 3 days And Invoiced <> yes)"
Finally i Received the e-mail alert,
I have received the mail alert "shipped not invoiced".
The problem is in the e-mail alert i can't identify from which packling slip the alert has been generated, since there is no order number. no customer name and also there is no plackslip ID.
But from the system generated mail alert i.e, In Global Alert such as "quote has been quoted" ,etc.. i have received mail with quotation number, only the mail which is created through BAM does not contain scuh detail.How do get detail about for which part or order or packslip the mail has originally been generated? Is there any way to specify in the rule?
The solution would be more appreciated,
Thanks in Advance,
Regards,
Deepa.M


____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ

[Non-text portions of this message have been removed]
I am running V 8.03.305. I would recommend to use BPM rather then
BAM. It is my understanding that BAM never got to the level you are
looking for here. BPM is its replacement and allows you to insert
any tables/fields you need. I have actually used this to setup an
email alert for PO Approval and shows PO, Date, and Buyer. I
originally tried this in BAM and could never get the information to
attach.

--- In vantage@yahoogroups.com, Deepa <deepait_10@...> wrote:
>
> Hi,
> In Vantage 8.03.404, I have tried to send alert message
for 'shipped not invoiced' which is as follows,
> 1. In Business Activity Manager, I select the table name called
ShipHead, Under table ShipHead I select the fields such as Invoiced,
ShipStatus, ShipDate.
> 2. In Actions Tab, I check send alert check box and I gave email
address, label, alert text, To address.
> 3. In Rules tab, i create a rule such as " for alert ( shipdate< 3
days And Invoiced <> yes)"
> Finally i Received the e-mail alert,
> I have received the mail alert "shipped not invoiced".
> The problem is in the e-mail alert i can't identify from which
packling slip the alert has been generated, since there is no order
number. no customer name and also there is no plackslip ID.
> But from the system generated mail alert i.e, In Global Alert such
as "quote has been quoted"Â ,etc.. i have received mail with quotation
number, only the mail which is created through BAM does not contain
scuh detail.How do get detail about for which part or order or
packslip the mail has originally been generated? Is there any way to
specify in the rule?
> The solution would be more appreciated,
> Thanks in Advance,
> Regards,
> Deepa.M
>
>
>
______________________________________________________________________
______________
> Be a better friend, newshound, and
> know-it-all with Yahoo! Mobile. Try it now.
http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
>
> [Non-text portions of this message have been removed]
>
Jplehr is right I think you should use a BMP, I haven't played with the
BMP's yet so I can't say put I'm told there better to use to send out
detailed information. However you can still use a BAM if you want. We use
BAMs to send out e-mails with each new sales orders, I wrote a .p program
that attached the order detail to the e-mail. Below is the code I used:

/* Finshed: 9/14/2006 3:48:21 PM Updated 9/13/2007 to fix shipto*/
{ud/GlbAlert.i &TableName = "OrderHed"}
DEFINE VARIABLE NewEmailBody AS CHARACTER NO-UNDO.
FIND Customer WHERE (Customer.Company = OrderHed.Company) AND
(Customer.CustNum = OrderHed.CustNum)
NO-LOCK.
FIND OrderDtl WHERE (OrderDtl.Company = OrderHed.Company) AND
(OrderDtl.Ordernum = Orderhed.OrderNum)
NO-LOCK NO-ERROR.
/*Dont send email if "SEND EMAIL" checkbox is not checked */
If NOT (orderhed.checkbox02) THEN DO:
RETURN "CANCEL SEND":U.
END.
/* Create email */
ASSIGN Email-To = " nhutchins@...; nhutchins@..."
Email-Subject = "New Order# " + STRING(OrderHed.OrderNum)
/* Create the new body of the email */
NewEmailBody = "~nOrder Number: " + STRING(OrderHed.OrderNum)
+ "~n~nCustomer: " + STRING(Customer.Name)
+ "~n~nShip By: " + (IF OrderHed.RequestDate = ?
THEN "see below" ELSE STRING(orderhed.RequestDate))
+ "~n~nOrder Date: " + STRING(Orderhed.OrderDate)
+ "~n~nOrder Lines:~n".
/* Lines of Order */
FOR EACH OrderDtl of OrderHed no-lock:
Assign NewEmailBody = NewEmailBody
+ " Item " + STRING(OrderDtl.OrderLine) + ": " +
STRING(OrderDtl.PartNum) + " " + STRING(OrderDtl.LineDesc)
+ (IF OrderHed.RequestDate = ? THEN " Ship By: " +
STRING(OrderDtl.RequestDate) ELSE "")
+ "~n".
END.
ASSIGN NewEmailBody = NewEmailBody
+ "~n~nSales Person: " + STRING(OrderHed.SalesRepList)
+ "~n~nDO NOT REPLY TO THIS E-MAIl ACCOUNT, IT DOES
NOT GET REVIEW!".
/* Print Email Body */
ASSIGN Email-Text = NewEmailBody

Below is what the e-mail looks like:

Subject: New Order# 26625

Order Number: 26625
Customer: RF Specialties of Missouri
Ship By: 05/16/08
Order Date: 05/12/08
Order Lines:
Item 1: 96373-G501 6812B-2-97.10
Item 2: 96373-RETURN RMA 1178 - Standby Antenna Return
Authorization
Sales Person: JROHRER
DO NOT REPLY TO THIS E-MAIl ACCOUNT, IT DOES NOT GET REVIEW!

Hope this helps, if you need help let me know.

Norman


[Non-text portions of this message have been removed]
Norman,



This is an old thread, but I think it will work with a project that I am
working on. When you use "ASSIGN email-TO" or any of the other Assigns
replace setup in the BAM itself?



Steve



-----Original Message-----
From: Norman Hutchins [mailto:nhutchins@...]
Sent: May 12, 2008 12:24 PM
To: vantage@yahoogroups.com
Subject: [Vantage] Re: E-mail alert with detail



Jplehr is right I think you should use a BMP, I haven't played with the
BMP's yet so I can't say put I'm told there better to use to send out
detailed information. However you can still use a BAM if you want. We use
BAMs to send out e-mails with each new sales orders, I wrote a .p program
that attached the order detail to the e-mail. Below is the code I used:

/* Finshed: 9/14/2006 3:48:21 PM Updated 9/13/2007 to fix shipto*/
{ud/GlbAlert.i &TableName = "OrderHed"}
DEFINE VARIABLE NewEmailBody AS CHARACTER NO-UNDO.
FIND Customer WHERE (Customer.Company = OrderHed.Company) AND
(Customer.CustNum = OrderHed.CustNum)
NO-LOCK.
FIND OrderDtl WHERE (OrderDtl.Company = OrderHed.Company) AND
(OrderDtl.Ordernum = Orderhed.OrderNum)
NO-LOCK NO-ERROR.
/*Dont send email if "SEND EMAIL" checkbox is not checked */
If NOT (orderhed.checkbox02) THEN DO:
RETURN "CANCEL SEND":U.
END.
/* Create email */
ASSIGN Email-To = " nhutchins@shively. <mailto:nhutchins%40shively.com> com;
nhutchins@howelllab <mailto:nhutchins%40howelllabs.com> s.com"
Email-Subject = "New Order# " + STRING(OrderHed.OrderNum)
/* Create the new body of the email */
NewEmailBody = "~nOrder Number: " + STRING(OrderHed.OrderNum)
+ "~n~nCustomer: " + STRING(Customer.Name)
+ "~n~nShip By: " + (IF OrderHed.RequestDate = ?
THEN "see below" ELSE STRING(orderhed.RequestDate))
+ "~n~nOrder Date: " + STRING(Orderhed.OrderDate)
+ "~n~nOrder Lines:~n".
/* Lines of Order */
FOR EACH OrderDtl of OrderHed no-lock:
Assign NewEmailBody = NewEmailBody
+ " Item " + STRING(OrderDtl.OrderLine) + ": " +
STRING(OrderDtl.PartNum) + " " + STRING(OrderDtl.LineDesc)
+ (IF OrderHed.RequestDate = ? THEN " Ship By: " +
STRING(OrderDtl.RequestDate) ELSE "")
+ "~n".
END.
ASSIGN NewEmailBody = NewEmailBody
+ "~n~nSales Person: " + STRING(OrderHed.SalesRepList)
+ "~n~nDO NOT REPLY TO THIS E-MAIl ACCOUNT, IT DOES
NOT GET REVIEW!".
/* Print Email Body */
ASSIGN Email-Text = NewEmailBody

Below is what the e-mail looks like:

Subject: New Order# 26625

Order Number: 26625
Customer: RF Specialties of Missouri
Ship By: 05/16/08
Order Date: 05/12/08
Order Lines:
Item 1: 96373-G501 6812B-2-97.10
Item 2: 96373-RETURN RMA 1178 - Standby Antenna Return
Authorization
Sales Person: JROHRER
DO NOT REPLY TO THIS E-MAIl ACCOUNT, IT DOES NOT GET REVIEW!

Hope this helps, if you need help let me know.

Norman

[Non-text portions of this message have been removed]





[Non-text portions of this message have been removed]
Yes Steve, the ASSIGN email-TO replaces whatever you have in the To field of
the BAM. I normal just put myself in the BAM TO field (because you have to
have something) and then used the ASSIGN for the really addresses.



Another tip I heard recently that I haven't used yet is to setup an e-mail
alias that forwards to the list of people, instead of including all the
address in the .p program, which might makes it a little easier to manage
when you need to edited the list.



Hope that helps.



Norman Hutchins

Network Administrator

Howell Laboratories, Inc.









[Non-text portions of this message have been removed]
Norman,



I was going to e-mail order information when shipped to the internal sales
person that entered the order. I thought that I would lookup the user that
entered order and try to pull in e-mail address that is entered in the user
table and lookup outside sales person and add there e-mail also.



Steve



-----Original Message-----
From: Norman Hutchins [mailto:nhutchins@...]
Sent: November 19, 2008 8:39 AM
To: vantage@yahoogroups.com
Subject: [Vantage] Re: E-mail alert with detail



Yes Steve, the ASSIGN email-TO replaces whatever you have in the To field of
the BAM. I normal just put myself in the BAM TO field (because you have to
have something) and then used the ASSIGN for the really addresses.

Another tip I heard recently that I haven't used yet is to setup an e-mail
alias that forwards to the list of people, instead of including all the
address in the .p program, which might makes it a little easier to manage
when you need to edited the list.

Hope that helps.

Norman Hutchins

Network Administrator

Howell Laboratories, Inc.

[Non-text portions of this message have been removed]





[Non-text portions of this message have been removed]
> I was going to e-mail order information when shipped to the internal sales
> person that entered the order. I thought that I would lookup the user that
> entered order and try to pull in e-mail address that is entered in the
> user
> table and lookup outside sales person and add there e-mail also.

That's clever Steve. But if you wanted to send a copy to the sales person's
manager then a distribution list would seem to work better.

Mark W.
Where would you pick up the distribution list? Or are you thinking aliases?



Steve



-----Original Message-----
From: Mark Wonsil [mailto:mark_wonsil@...]
Sent: November 19, 2008 9:36 AM
To: vantage@yahoogroups.com
Subject: RE: [Vantage] Re: E-mail alert with detail



> I was going to e-mail order information when shipped to the internal sales
> person that entered the order. I thought that I would lookup the user that
> entered order and try to pull in e-mail address that is entered in the
> user
> table and lookup outside sales person and add there e-mail also.

That's clever Steve. But if you wanted to send a copy to the sales person's
manager then a distribution list would seem to work better.

Mark W.





[Non-text portions of this message have been removed]
>
> Where would you pick up the distribution list? Or are you thinking
> aliases?

Good point. I meant distribution lists at your mail server and not in
anyone's personal Outlook. We use Exchange but every mail system I have ever
worked with allows one to create a distribution list that looks like an
email address to the outside but sends a copy of the message to each person
in the list. The domain rmgfelm.com uses Exim as a mail transport agent. So
you probably use a front-end like CPanel to administer your email accounts.
This is where you would set up your server-based distribution lists.

Mark W.
Can you help me with trimming the description field to 15 characters?



Steve



-----Original Message-----
From: Norman Hutchins [mailto:nhutchins@...]
Sent: November 19, 2008 8:39 AM
To: vantage@yahoogroups.com
Subject: [Vantage] Re: E-mail alert with detail



Yes Steve, the ASSIGN email-TO replaces whatever you have in the To field of
the BAM. I normal just put myself in the BAM TO field (because you have to
have something) and then used the ASSIGN for the really addresses.

Another tip I heard recently that I haven't used yet is to setup an e-mail
alias that forwards to the list of people, instead of including all the
address in the .p program, which might makes it a little easier to manage
when you need to edited the list.

Hope that helps.

Norman Hutchins

Network Administrator

Howell Laboratories, Inc.

[Non-text portions of this message have been removed]





[Non-text portions of this message have been removed]
How about substring(part.part-desc,1,15)?

From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com] On Behalf Of
vantage
Sent: Wednesday, November 19, 2008 3:41 PM
To: vantage@yahoogroups.com
Subject: RE: [Vantage] Re: E-mail alert with detail

Can you help me with trimming the description field to 15 characters?

Steve

-----Original Message-----
From: Norman Hutchins [mailto:nhutchins@...
<mailto:nhutchins%40howelllabs.com> ]
Sent: November 19, 2008 8:39 AM
To: vantage@yahoogroups.com <mailto:vantage%40yahoogroups.com>
Subject: [Vantage] Re: E-mail alert with detail

Yes Steve, the ASSIGN email-TO replaces whatever you have in the To field of
the BAM. I normal just put myself in the BAM TO field (because you have to
have something) and then used the ASSIGN for the really addresses.

Another tip I heard recently that I haven't used yet is to setup an e-mail
alias that forwards to the list of people, instead of including all the
address in the .p program, which might makes it a little easier to manage
when you need to edited the list.

Hope that helps.

Norman Hutchins

Network Administrator

Howell Laboratories, Inc.

[Non-text portions of this message have been removed]

[Non-text portions of this message have been removed]



[Non-text portions of this message have been removed]
I will give this a try tomorrow morning!



Thanks



Steve



-----Original Message-----
From: Carl Peterson [mailto:cpeterson@...]
Sent: November 19, 2008 3:29 PM
To: vantage@yahoogroups.com
Subject: RE: [Vantage] Re: E-mail alert with detail



How about substring(part.part-desc,1,15)?

From: vantage@yahoogroups <mailto:vantage%40yahoogroups.com> .com
[mailto:vantage@yahoogroups <mailto:vantage%40yahoogroups.com> .com] On
Behalf Of
vantage
Sent: Wednesday, November 19, 2008 3:41 PM
To: vantage@yahoogroups <mailto:vantage%40yahoogroups.com> .com
Subject: RE: [Vantage] Re: E-mail alert with detail

Can you help me with trimming the description field to 15 characters?

Steve

-----Original Message-----
From: Norman Hutchins [mailto:nhutchins@howelllab
<mailto:nhutchins%40howelllabs.com> s.com
<mailto:nhutchins%40howelllabs.com> ]
Sent: November 19, 2008 8:39 AM
To: vantage@yahoogroups <mailto:vantage%40yahoogroups.com> .com
<mailto:vantage%40yahoogroups.com>
Subject: [Vantage] Re: E-mail alert with detail

Yes Steve, the ASSIGN email-TO replaces whatever you have in the To field of
the BAM. I normal just put myself in the BAM TO field (because you have to
have something) and then used the ASSIGN for the really addresses.

Another tip I heard recently that I haven't used yet is to setup an e-mail
alias that forwards to the list of people, instead of including all the
address in the .p program, which might makes it a little easier to manage
when you need to edited the list.

Hope that helps.

Norman Hutchins

Network Administrator

Howell Laboratories, Inc.

[Non-text portions of this message have been removed]

[Non-text portions of this message have been removed]


[Non-text portions of this message have been removed]





[Non-text portions of this message have been removed]
I'm not a progress programmer by any means. The .p program that I posted, I
created by taking a couple of example .p programs, edited and combined a
little. And some help from this group too.



I also bought a book, Progress OpenEdge Development: Progress 4GL Handbook
by John Sadd (ISBN 0-923562-04-4) which I see is available online
(http://www.psdn.com/library/servlet/KbServlet/download/1142-102-953/dvhbk.p
df)



In that book there are three trim functions: (pages 2-22 to 2-23)



Function: LEFT-TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from the beginning of the string. The trim-chars argument is optional and
defaults to all white space (spaces, tabs, carriage returns, and line
feeds).



Function: RIGHT-TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from the end of the string. The trim-chars argument is optional and
defaults to all white space.



Function: TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from both the beginning and the end of the string. The trim-chars argument
is optional and defaults to all white space.



Hope this helps, maybe someone else out there will be able to give you an
example of the syntax.





Norman Hutchins

Network Administrator

Howell Laboratories, Inc.







[Non-text portions of this message have been removed]
Right and Left Trim Functions are based on a specific character like an * or
/ or | or whatever. It is not designed to parse a string based on a
specific number of characters like the Progress statement of substring. The
Progress string statement would work, too. String(part.partdesc,"x(15)")

From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com] On Behalf Of
Norman Hutchins
Sent: Wednesday, November 19, 2008 5:15 PM
To: vantage@yahoogroups.com
Subject: [Vantage] Re: E-mail alert with detail

I'm not a progress programmer by any means. The .p program that I posted, I
created by taking a couple of example .p programs, edited and combined a
little. And some help from this group too.

I also bought a book, Progress OpenEdge Development: Progress 4GL Handbook
by John Sadd (ISBN 0-923562-04-4) which I see is available online
(http://www.psdn.com/library/servlet/KbServlet/download/1142-102-953/dvhbk.p
df)

In that book there are three trim functions: (pages 2-22 to 2-23)

Function: LEFT-TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from the beginning of the string. The trim-chars argument is optional and
defaults to all white space (spaces, tabs, carriage returns, and line
feeds).

Function: RIGHT-TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from the end of the string. The trim-chars argument is optional and
defaults to all white space.

Function: TRIM

Arguments: string AS CHAR. trim-chars AS CHAR

Returned Value: CHARACTER - The input string with the trim-chars removed
from both the beginning and the end of the string. The trim-chars argument
is optional and defaults to all white space.

Hope this helps, maybe someone else out there will be able to give you an
example of the syntax.

Norman Hutchins

Network Administrator

Howell Laboratories, Inc.

[Non-text portions of this message have been removed]



[Non-text portions of this message have been removed]