Microsoft Dynamics AX/AX 2009
Alert 메세지 보내기
Isaac Lee
2011. 6. 9. 10:26
다음 소스코드를 사용하면 Dynamics AX의 Alert를 만들수 있습니다. 특정사용자 혹은 여러 사용자에게 동시에 메세지를 보내고 싶을 때나 Dynamics AX의 기본 Alert 기능으로는 핸들링 하지 못하는 이벤트에서 메세지를 보내고 싶을 때 사용할 수 있습니다.
static void sendAlert(Args _args) { EventInbox inbox; EventInboxId inboxId; inboxId = EventInbox::nextEventId(); inbox.initValue(); inbox.ShowPopup = NoYes::Yes; inbox.Subject = "Happy DAXing!!"; // 제목 inbox.Message = "http://www.dynamicsax.kr"; // 내용 inbox.SendEmail = false; inbox.UserId = curUserID(); // 수신인 ID inbox.InboxId = inboxId; inbox.AlertCreatedDate = systemdateget(); inbox.AlertCreateTime = timeNow(); inbox.insert(); } |