<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-8725859366263791201</id><updated>2024-10-17T23:54:40.313+03:00</updated><category term="Dynamics AX"/><category term="AX 2012"/><category term="Development"/><category term="Workflow"/><category term="Business Intellegince"/><category term="AX Administration"/><category term="SQL"/><category term="SSRS"/><category term="X++"/><category term="Reports"/><category term="Batch Framework"/><category term="Integration"/><category term="Security"/><category term="Enterprise Portal"/><category term="AIF"/><category term="Dynamic in C# 4.0: Introducing the ExpandoObject"/><category term="Inventory"/><category term="SharePoint"/><title type='text'>Saber Mahdy</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>242</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-645770882089744207</id><published>2019-11-03T17:43:00.002+03:00</published><updated>2019-11-03T17:43:33.418+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><title type='text'>Set up excise taxes in Dynamics AX</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;div class=&quot;mentions-texteditor__content&quot; style=&quot;background: rgb(255, 255, 255); border: 0px; box-sizing: inherit; color: rgba(0, 0, 0, 0.9); font-family: -apple-system, system-ui, BlinkMacSystemFont, &amp;quot;Segoe UI&amp;quot;, Roboto, &amp;quot;Helvetica Neue&amp;quot;, &amp;quot;Fira Sans&amp;quot;, Ubuntu, Oxygen, &amp;quot;Oxygen Sans&amp;quot;, Cantarell, &amp;quot;Droid Sans&amp;quot;, &amp;quot;Apple Color Emoji&amp;quot;, &amp;quot;Segoe UI Emoji&amp;quot;, &amp;quot;Segoe UI Symbol&amp;quot;, &amp;quot;Lucida Grande&amp;quot;, Helvetica, Arial, sans-serif; font-size: 18px; line-height: 1.5; padding: 0px; vertical-align: baseline;&quot;&gt;
In regard to implementing Excise tax in Saudi Arabia, I would like to share the link below to all companies have been implemented Dynamics AX 2012&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;mentions-texteditor__content&quot; style=&quot;background: rgb(255, 255, 255); border: 0px; box-sizing: inherit; color: rgba(0, 0, 0, 0.9); font-family: -apple-system, system-ui, BlinkMacSystemFont, &amp;quot;Segoe UI&amp;quot;, Roboto, &amp;quot;Helvetica Neue&amp;quot;, &amp;quot;Fira Sans&amp;quot;, Ubuntu, Oxygen, &amp;quot;Oxygen Sans&amp;quot;, Cantarell, &amp;quot;Droid Sans&amp;quot;, &amp;quot;Apple Color Emoji&amp;quot;, &amp;quot;Segoe UI Emoji&amp;quot;, &amp;quot;Segoe UI Symbol&amp;quot;, &amp;quot;Lucida Grande&amp;quot;, Helvetica, Arial, sans-serif; font-size: 18px; line-height: 1.5; padding: 0px; vertical-align: baseline;&quot;&gt;
&lt;a href=&quot;https://docs.microsoft.com/en-us/dynamicsax-2012/appuser-itpro/pol-set-up-excise-taxes&quot;&gt;https://docs.microsoft.com/en-us/dynamicsax-2012/appuser-itpro/pol-set-up-excise-taxes&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/645770882089744207/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2019/11/set-up-excise-taxes-in-dynamics-ax.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/645770882089744207'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/645770882089744207'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2019/11/set-up-excise-taxes-in-dynamics-ax.html' title='Set up excise taxes in Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-1058486127750714669</id><published>2016-11-13T09:26:00.001+03:00</published><updated>2016-11-13T09:26:42.873+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Dynamics AX"/><title type='text'>Microsoft Dynamics 365: What You Need to Know</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
In July 2016, Microsoft announced it would be combining its CRM and ERP solutions into a single cloud-based bundle called&amp;nbsp;&lt;a href=&quot;http://www.meritsolutions.com/products/microsoft-dynamics-365/&quot; style=&quot;border: 0px; color: rgb(7, 190, 229) !important; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; outline: 0px; padding: 0px; text-decoration: none; transition: color 0.2s linear; vertical-align: baseline;&quot; target=&quot;_blanc&quot; title=&quot;Microsoft Dynamics 365&quot;&gt;Microsoft Dynamics 365&lt;/a&gt;. The announcement raised many questions among users about whether it will replace current Microsoft products and how users can implement these solutions.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
One thing is clear, though – Dynamics 365 enables employees to work from anywhere at any time through their mobile devices, and Microsoft believes this will be a game changer for its customers. Read on to learn more about Dynamics 365 and mobility.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
&lt;span id=&quot;more-7377&quot; style=&quot;border: 0px; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;&lt;/span&gt;&lt;/div&gt;
&lt;h2 style=&quot;background-color: white; border: 0px; color: #333333; font-family: &amp;quot;open sans&amp;quot;; font-size: 21px; font-stretch: inherit; font-weight: normal; line-height: 27px; margin: 16px 0px 10px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
Microsoft’s New Approach to Business Applications&lt;/h2&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
Microsoft has billed Dynamics 365 as “the next generation of intelligent business applications” that “enable organizations to grow, evolve, and transform.” But, what does that mean in practice?&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
According to Microsoft spokespeople, Dynamics 365 is a re-architecting and repackaging of the capabilities of Dynamics CRM,&amp;nbsp;&lt;a href=&quot;http://www.meritsolutions.com/products/dynamics_ax/&quot; style=&quot;border: 0px; color: rgb(7, 190, 229) !important; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; outline: 0px; padding: 0px; text-decoration: none; transition: color 0.2s linear; vertical-align: baseline;&quot; target=&quot;_blanc&quot; title=&quot;Microsoft Dynamics AX Services&quot;&gt;Dynamics AX&lt;/a&gt;, and a small business SaaS offering called “Project Madeira.” Furthermore, Dynamics 365 complements Microsoft’s current lineup of CRM and ERP solutions (the existing ERP systems will not go away). And, it will connect to Office 365, making it simple for users to communicate, share, and request information from within one platform.&lt;/div&gt;
&lt;h2 style=&quot;background-color: white; border: 0px; color: #333333; font-family: &amp;quot;open sans&amp;quot;; font-size: 21px; font-stretch: inherit; font-weight: normal; line-height: 27px; margin: 16px 0px 10px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
A New Licensing Model&lt;/h2&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
Microsoft offers two licensing models for Dynamics 365: an application-based model and a role-based model.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
Under the application-based model, businesses can purchase as many apps as they need, even if it’s only a single app. Conversely, the role-based model enables employees to access mission-critical apps. For example, a salesperson doesn’t just need to use a CRM app. He or she also needs data from field service representatives and the customer service team. The information from those app categories allows the salesperson to not merely do his or her job, but excel at it.&lt;/div&gt;
&lt;h2 style=&quot;background-color: white; border: 0px; color: #333333; font-family: &amp;quot;open sans&amp;quot;; font-size: 21px; font-stretch: inherit; font-weight: normal; line-height: 27px; margin: 16px 0px 10px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
What People Are Saying about Dynamics 365&lt;/h2&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
The Dynamics 365 announcement attracted a great deal of attention from&amp;nbsp;&lt;a href=&quot;https://techcrunch.com/2016/07/06/microsoft-gives-frenemy-salesforce-a-shove-with-new-dynamics-365-integrated-cloud-platform/&quot; style=&quot;border: 0px; color: rgb(7, 190, 229) !important; font-family: inherit; font-size: inherit; font-stretch: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; line-height: inherit; margin: 0px; outline: 0px; padding: 0px; text-decoration: none; transition: color 0.2s linear; vertical-align: baseline;&quot; target=&quot;_blanc&quot; title=&quot;Microsoft gives Salesforce a shove with new Dynamics 365 integrated cloud platform&quot;&gt;industry analysts&lt;/a&gt;. They note that it represents a new approach to CRM and ERP applications from the software giant.&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; border: 0px; color: #555555; font-family: &amp;quot;open sans&amp;quot;, arial, sans-serif; font-size: 14px; font-stretch: inherit; line-height: inherit; margin-bottom: 12px; padding: 0px; text-align: justify; vertical-align: baseline;&quot;&gt;
&lt;a href=&quot;http://www.meritsolutions.com/microsoft-dynamics-365/microsoft-dynamics-365-what-you-need-to-know/&quot; target=&quot;_blank&quot;&gt;Read More&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/1058486127750714669/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2016/11/microsoft-dynamics-365-what-you-need-to.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/1058486127750714669'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/1058486127750714669'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2016/11/microsoft-dynamics-365-what-you-need-to.html' title='Microsoft Dynamics 365: What You Need to Know'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-4850906655867970871</id><published>2016-05-01T11:17:00.001+03:00</published><updated>2016-05-01T11:17:24.889+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Development"/><category scheme="http://www.blogger.com/atom/ns#" term="X++"/><title type='text'>How to Delete Company Transactions in AX 2012 including Trial balance?</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;To delete Transactions
data inside any company in ax, you can do by using the class
SysDatabaseTransDelete under AOT.&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;But you may facing an
issue since the Trial Balance will not be deleted so,&amp;nbsp;to delete GL Trans
by deleting the following tables:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;GeneralJournalAccountEntry&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;GeneralJournalEntry&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;LedgerEntryJournal&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;LedgerEntry&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;Ledgerjournaltrans&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;Ledgerjournaltable&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;To remove the Trial
Balance you have to follow the steps below:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;1-) Modify
&#39;handleTable()&#39; method by adding 2 new cases&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: red; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;Case TableGroup::TransactionHeader:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: red; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;Case
TableGroup::TransactionLine:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt; margin-left: .25in; margin-right: 0in; margin-top: 0in; text-indent: -.25in;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;void&amp;nbsp;handleTable(SysDictTable
sysDictTable)&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;{&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;TableGroup&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;tableGroup;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if&amp;nbsp;(tableSet.in(sysDictTable.id()))&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;return;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;tableSet.add(sysDictTable.id());&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if&amp;nbsp;(sysDictTable
&amp;amp;&amp;amp; !sysDictTable.isTmp() &amp;amp;&amp;amp; !sysDictTable.isMap())&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;tableGroup
= sysDictTable.tableGroup();&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;//
Handle company specific tables to be deleted&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if&amp;nbsp;(sysDictTable.dataPrCompany())&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;switch(tableGroup)&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::Transaction:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: red; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::TransactionHeader:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: red; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::TransactionLine:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::WorksheetHeader:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::WorksheetLine:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;this.handleTransTable(sysDictTable);&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;break;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;default:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;this.handleNonTransTable(sysDictTable);&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;break;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;else&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;//
Handle global tables to be deleted&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;switch(tableGroup)&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::Transaction:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: red; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::TransactionHeader:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: red; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::TransactionLine:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::TransactionHeader
:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::WorksheetHeader:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;case&amp;nbsp;TableGroup::WorksheetLine:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;this.handleGlobalTransTable(sysDictTable);&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;break;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;default:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;break;&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;background: white; line-height: 15.0pt; margin-bottom: 6.0pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;2) Add a new method to
handle LEDGERJOURNALTABLE:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;private void
deleteLedgerJournalTables()&lt;br /&gt;
{&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp; &amp;nbsp;
GeneralJournalEntry &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; GJEntry;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; GeneralJournalAccountEntry &amp;nbsp;GJAEntry;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; LedgerJournalTable &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;ledgerjournalTable;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; LedgerEntryJournal &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;
&amp;nbsp;ledgerEntryJournal;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; ttsBegin;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; while select forupdate LedgerJournalTable&lt;br /&gt;
&amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; while select forUpdate ledgerEntryJournal&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; where
ledgerEntryJournal.JournalNumber == ledgerjournalTable.JournalNum&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; //&amp;amp;&amp;amp; &amp;nbsp;
&amp;nbsp;ledgerEntryJournal.dataAreaId == ledgerjournalTable.dataAreaId&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; while select forUpdate GJEntry&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; where
GJEntry.LedgerEntryJournal == ledgerEntryJournal.RecId&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; delete_from
GJAEntry&amp;nbsp;&amp;nbsp;where GJAEntry.GeneralJournalEntry == GJEntry.RecId;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; GJEntry.delete();&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ledgerEntryJournal.delete();&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; LedgerJournalTable.delete();&lt;br /&gt;
&amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; ttsCommit;&lt;br /&gt;
}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;3) Modify the &#39;handleTransTable()&#39;
method to call the above method&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;void
handleTransTable(SysDictTable sysDictTable)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; &amp;nbsp; switch(sysDictTable.id())&lt;br /&gt;
&amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; case tablenum(CustCollectionLetterLine):&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; case tablenum(InventDim):&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; case tablenum(DocuRef):&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; case tablenum(DirPartyRelationship) :&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; break;&lt;br /&gt;
&amp;nbsp;&lt;b&gt;&lt;i&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;case tablenum(LedgerJournalTable)
:&amp;nbsp;&lt;/i&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;i&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;
this.deleteLedgerJournalTables();&lt;/i&gt;&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;i&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; break;&lt;/i&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; default:&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; this.deleteTable(sysDictTable);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; break;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; }&lt;br /&gt;
}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;4) You may have to
modify the &#39;deleteVoucher()&#39; method in the &#39;LedgerJournalTrans&#39; table to skip
over releasing non-existing voucher numbers&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;public server void
deleteVoucher(Voucher _voucher = this.Voucher)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; &amp;nbsp; LedgerJournalTable &amp;nbsp;ledgerJournalTable =
LedgerJournalTable::find(this.JournalNum);&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; if (! ledgerJournalTable.Posted &amp;amp;&amp;amp; !this.Transferred)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (_voucher &amp;amp;&amp;amp; !
LedgerJournalTrans::existTransMinusThis(this.JournalNum, _voucher, this.RecId))&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (this.checkVoucherNotUsed(ledgerJournalTable,
_voucher))&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if
(this.checkVoucherNotUsedDataSource(_voucher))&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; //
replace the voucher number so it can be re-used&lt;br /&gt;
&lt;b&gt;&lt;i&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;
&amp;nbsp; if (ledgerJournalTable.NumberSequenceTable) /* 28Nov12-Admin */&lt;/i&gt;&lt;/b&gt;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;
&amp;nbsp; NumberSeq::releaseNumber(ledgerJournalTable.NumberSequenceTable,
_voucher);&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if
(this.Voucher == _voucher)&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;
&amp;nbsp; // delete voucher template record if exists and the voucher on the line
is not being changed&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;
&amp;nbsp;
LedgerJournalTransVoucherTemplate::deleteForJournalOrVoucher(this.JournalNum,
_voucher);&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; }&lt;br /&gt;
}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;5) After running
&#39;SysDatabaseTransDelete&#39;, rebuild balances for the financial dimension sets
(General Ledger\Setup\Financial Dimensions\Financial dimension sets)&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;If you still have
non-zero amounts in the Trial balance then you must manually remove the &#39;left-over&#39;
rows in the shared tables (results of your previous executions of the
&#39;SysDatabaseTransDelete&#39;). Identify these entries in the &#39;LedgerEntryJournal&#39;
table then use the following job to clear them:&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;span style=&quot;color: #303131; font-family: &amp;quot;Segoe UI&amp;quot;,sans-serif; font-size: 11.5pt; mso-fareast-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;static void
tg_deleteTables(Args _args)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; &amp;nbsp; GeneralJournalEntry &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; GJEntry;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; GeneralJournalAccountEntry &amp;nbsp;GJAEntry;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; LedgerJournalTable &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;
&amp;nbsp;ledgerjournalTable;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; LedgerEntryJournal &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;
&amp;nbsp;ledgerEntryJournal;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; ttsBegin;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; while select forUpdate ledgerEntryJournal&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; where
ledgerEntryJournal.JournalNumber like &#39;clau*&#39; &amp;nbsp;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; while select forUpdate GJEntry&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; where
GJEntry.LedgerEntryJournal == ledgerEntryJournal.RecId&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; delete_from
GJAEntry&amp;nbsp;&amp;nbsp;where GJAEntry.GeneralJournalEntry == GJEntry.RecId;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; GJEntry.delete();&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ledgerEntryJournal.delete();&lt;br /&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp; &amp;nbsp; ttsCommit;&lt;br /&gt;
&amp;nbsp; &amp;nbsp; info(&#39;completed&#39;);&lt;br /&gt;
}&lt;/span&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;, serif; font-size: 13.5pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot; style=&quot;margin-bottom: 0.0001pt;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/4850906655867970871/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2016/05/how-to-delete-company-transactions-in.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/4850906655867970871'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/4850906655867970871'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2016/05/how-to-delete-company-transactions-in.html' title='How to Delete Company Transactions in AX 2012 including Trial balance?'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-9072153168199844925</id><published>2016-01-21T09:19:00.001+03:00</published><updated>2016-01-21T09:19:29.066+03:00</updated><title type='text'>12 Ways to Improve Your Productivity at Work</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
&lt;a data-mce-href=&quot;http://axconsulting.files.wordpress.com/2014/11/image7.png&quot; href=&quot;http://axconsulting.files.wordpress.com/2014/11/image7.png&quot; style=&quot;color: #00aadc;&quot;&gt;&lt;img alt=&quot;image&quot; border=&quot;0&quot; data-mce-src=&quot;http://axconsulting.files.wordpress.com/2014/11/image_thumb7.png&quot; data-mce-style=&quot;background-image: none; padding-top: 0; padding-left: 0; display: inline; padding-right: 0; border-width: 0;&quot; height=&quot;208&quot; src=&quot;http://axconsulting.files.wordpress.com/2014/11/image_thumb7.png&quot; style=&quot;background-image: none; border: 0px; display: inline; height: auto; max-width: 100%; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot; title=&quot;image&quot; width=&quot;322&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;h3 style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif;&quot;&gt;
&amp;nbsp;&lt;/h3&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
Between constant meetings, phone calls and emails, staying productive at work can be a challenge. However, the odds of staying productive can be greatly improved by taking some simple steps in order to stay efficient.&lt;/div&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
Here are 12 tips from the Bayt.com team to help you to make the most of your time at work:&lt;/div&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
&lt;strong&gt;1. Don’t let emails take over your day&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
We are all so accustomed to email that as soon as we see a new email in our inbox we instinctively click it on, focus on the content of the email, and respond. These seemingly tiny activities during the day can quickly add up to large amounts of time that not only cause your day to slip away, but also distract you from completing your current task.&lt;/div&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
If replying to or disposing of an e-mail takes less than two minutes, do it right away. Send less to receive less: Keep your e-mails short, and write fewer of them. Here are some tips from the career experts at Bayt.com to help you&amp;nbsp;&lt;a data-mce-href=&quot;http://www.bayt.com/en/career-article-2921/&quot; href=&quot;http://www.bayt.com/en/career-article-2921/&quot; style=&quot;color: #00aadc;&quot;&gt;control your work emails&lt;/a&gt;.&lt;/div&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
&lt;strong&gt;2. Eliminate unnecessary meetings&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
Face-to-face communication is essential (email is fraught with misinterpretation), but be ruthless about protecting your time. Avoid every meeting that isn’t truly necessary.&lt;/div&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px; margin-bottom: 24px;&quot;&gt;
&lt;strong&gt;3. Learn how to say ‘no’&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;color: #3d596d; font-family: Merriweather, Georgia, &#39;Times New Roman&#39;, Times, serif; font-size: 15px; line-height: 25.5px;&quot;&gt;
While everyone wants to be a good team player at work, saying ‘no’ is sometimes the right thing to do. If you are not the best person for a task, or if you have other pending deadlines, it is OK to turn down a work request.&amp;nbsp;&amp;nbsp;&lt;a data-mce-href=&quot;http://blog.bayt.com/2014/01/12-ways-to-improve-your-productivity-at-work/&quot; href=&quot;http://blog.bayt.com/2014/01/12-ways-to-improve-your-productivity-at-work/&quot; style=&quot;color: #00aadc;&quot;&gt;read more&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/9072153168199844925/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2016/01/12-ways-to-improve-your-productivity-at.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/9072153168199844925'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/9072153168199844925'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2016/01/12-ways-to-improve-your-productivity-at.html' title='12 Ways to Improve Your Productivity at Work'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-8774340547113158791</id><published>2016-01-21T09:04:00.000+03:00</published><updated>2016-01-21T09:04:39.766+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Dynamics AX"/><category scheme="http://www.blogger.com/atom/ns#" term="X++"/><title type='text'>How to post PO by Code in Dynamics AX</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;I have task to integrate Dynamics AX with another application by posting PO from out side Dynamics AX, so I used AIF and build new web service to be used from out of AX and call the method below to post PO (packing slip, or invoice) .&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;public str CreatePostProductReceipt(PurchId _PurchId, Num _PackingSlip, ItemId&amp;nbsp; Itemid, Qty qty,&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;InventSiteId&amp;nbsp; InventSiteId =&#39;&#39;, InventLocationId&amp;nbsp; InventLocationId= &#39;&#39; , inventBatchid batchid = &#39;&#39;, InventSerialId&amp;nbsp; serialId = &#39;&#39;, inventsizeId inventsizeId =&#39;&#39;, InventColorId InventColorId =&#39;&#39;)&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;{&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;PurchFormLetter&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; purchFormLetter;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;PurchParmUpdate&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; purchParmUpdate;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;PurchParmTable&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; purchParmTable;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;PurchParmLine&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; purchParmLine;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;PurchTable&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; purchTable;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;PurchLine&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; purchLine;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;PurchId&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; purchId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;Num&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; packingSlipId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;InventDim&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventDim;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;str&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ret=&#39;&#39;;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;System.Exception&amp;nbsp;&amp;nbsp;&amp;nbsp; err;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;packingSlipId&amp;nbsp;&amp;nbsp; = _PackingSlip;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchTable&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = PurchTable::find(_PurchId);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;ttsBegin;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;try&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;{&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;// Create PurchParamUpdate table&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormletter = PurchFormLetter::construct(DocumentStatus::PackingSlip); // to post invoice change to DocumentStatus::invoice&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.createParmUpdate(true);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmUpdate = PurchFormLetter.purchParmUpdate();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;// Set PurchParmTable table&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.clear();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.TransDate&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = SystemDateGet();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.Ordering&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = DocumentStatus::PackingSlip;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.ParmJobStatus&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = ParmJobStatus::Waiting;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.Num&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = packingSlipId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.PurchId&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchTable.PurchId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.PurchName&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchTable.PurchName;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.DeliveryName&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchTable.DeliveryName;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.OrderAccount&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchTable.OrderAccount;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.CurrencyCode&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchTable.CurrencyCode;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.InvoiceAccount&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchTable.InvoiceAccount;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.ParmId&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchParmUpdate.ParmId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmTable.insert();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;// Set PurchParmLine table&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;while select purchLine&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;where purchLine.PurchId == purchTable.purchId &amp;amp;&amp;amp; purchline.ItemId == Itemid&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;{&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.InitFromPurchLine(purchLine);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;inventDim = purchline.inventDim(true);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;// Set batch and serial number&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;if(InventSiteId != &#39;&#39;)&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;inventDim.InventSiteId = InventSiteId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;if(InventLocationId != &#39;&#39;)&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;inventDim.InventLocationId = InventLocationId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;if(batchid != &#39;&#39;)&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;inventDim.inventBatchId = batchId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;if(serialid != &#39;&#39;)&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;inventDim.inventSerialId = serialID;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;if(inventsizeId != &#39;&#39;)&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;inventDim.inventsizeId = inventsizeId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;if(InventColorId != &#39;&#39;)&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;inventDim.InventColorId = InventColorId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.InventDimId = inventDim::findOrCreate(inventdim).inventDimId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.ReceiveNow&amp;nbsp;&amp;nbsp;&amp;nbsp; = 1 ; //PurchLine.PurchQty;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.setInventReceiveNow();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.ParmId&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchParmTable.ParmId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.TableRefId&amp;nbsp;&amp;nbsp;&amp;nbsp; = purchParmTable.TableRefId;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.setQty(DocumentStatus::PackingSlip, false, true);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.setLineAmount();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchParmLine.insert();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;}&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;ttsCommit;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter = PurchFormLetter::construct(DocumentStatus::PackingSlip);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.transDate(systemDateGet());&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.proforma(false);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.specQty(PurchUpdate::PackingSlip);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.purchTable(purchTable);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;// This is the ID we hard code as the product receipt ID, if we do the posting via UI&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;// user would have the option to manually enter this value&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.parmParmTableNum(purchParmTable.ParmId);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.parmId(purchParmTable.ParmId);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.purchParmUpdate(purchparmupdate);&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;purchFormLetter.run();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;return &quot;OK&quot;;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;}&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;catch (Exception::CLRError)&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;{&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;err = CLRInterop::getLastException();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;ret = err.ToString();&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;return ret;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;}&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;Return &quot;Error&quot;;&lt;/span&gt;&lt;br style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot; /&gt;&lt;span style=&quot;background-color: #fefdfa; color: #333333; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18.2px;&quot;&gt;}&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/8774340547113158791/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2016/01/how-to-post-po-by-code-in-dynamics-ax.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/8774340547113158791'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/8774340547113158791'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2016/01/how-to-post-po-by-code-in-dynamics-ax.html' title='How to post PO by Code in Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-3706067728476620295</id><published>2015-06-04T10:33:00.001+03:00</published><updated>2015-06-04T10:33:31.085+03:00</updated><title type='text'>Inventory Closing slow</title><content type='html'>May The below link lead to you to solve Dynamics ax closing slowness issue by creating new indexes in the main tables used in the recalculation and closing process in Dynamics ax.&lt;br /&gt;&lt;br /&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;a href=&quot;https://ax4dev.wordpress.com/tag/inventsettlement/&quot;&gt;Inventory Closing slow&lt;/a&gt;:&lt;br /&gt;&lt;br /&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;header class=&quot;entry-header&quot; style=&quot;color: #404040; font-family: &#39;Source Sans Pro&#39;, sans-serif; font-size: 14.3999996185303px; line-height: 23.0399990081787px; overflow: hidden; padding: 15px;&quot;&gt;&lt;/header&gt;&lt;br /&gt;&lt;br /&gt;
&lt;div style=&quot;-webkit-text-stroke-width: 0px; color: black; font-family: &#39;Times New Roman&#39;; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; margin: 0px; orphans: auto; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 1; word-spacing: 0px;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/3706067728476620295/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2015/06/inventory-closing-slow.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/3706067728476620295'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/3706067728476620295'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2015/06/inventory-closing-slow.html' title='Inventory Closing slow'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-6103009088721486099</id><published>2014-11-18T02:12:00.001+03:00</published><updated>2014-11-18T02:12:13.340+03:00</updated><title type='text'>12 Ways to Improve Your Productivity at Work</title><content type='html'>&lt;p&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhESEwZVzSnZjwua5rXkRPHYUyJ31xmJ1L0_BBwdj7dT7pDfUzlrs7dnRlFfFLVFfoAU0QS6TUpRVMVyObqEC0_R6ncLMtuSbwoPBolAh6kdnvIlUOZq5_T5a9Rjmak5GIKDEiPiO2wDQJW/s1600-h/image%25255B4%25255D.png&quot;&gt;&lt;img title=&quot;image&quot; style=&quot;border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px&quot; border=&quot;0&quot; alt=&quot;image&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEin5T1XmNxfbC_jXIHcCeUD_t7tdaAYAlJqMz-rD5VsUuppRVtv-AmQgp0DceBO22T1ToVHP8hlcIjehky-4UyC5zEJXrZuLywR5KCNg4qHNajeVXLNGgpWk1DECrRR7FglqKOelF-b6LNN/?imgmax=800&quot; width=&quot;322&quot; height=&quot;208&quot;&gt;&lt;/a&gt;&lt;/p&gt; &lt;h3&gt;&amp;nbsp;&lt;/h3&gt; &lt;p&gt;Between constant meetings, phone calls and emails, staying productive at work can be a challenge. However, the odds of staying productive can be greatly improved by taking some simple steps in order to stay efficient.&lt;/p&gt; &lt;p&gt;Here are 12 tips from the Bayt.com team to help you to make the most of your time at work:&lt;/p&gt; &lt;p&gt;&lt;strong&gt;1. Don’t let emails take over your day&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;We are all so accustomed to email that as soon as we see a new email in our inbox we instinctively click it on, focus on the content of the email, and respond. These seemingly tiny activities during the day can quickly add up to large amounts of time that not only cause your day to slip away, but also distract you from completing your current task.&lt;/p&gt; &lt;p&gt;If replying to or disposing of an e-mail takes less than two minutes, do it right away. Send less to receive less: Keep your e-mails short, and write fewer of them. Here are some tips from the career experts at Bayt.com to help you &lt;a href=&quot;http://www.bayt.com/en/career-article-2921/&quot;&gt;control your work emails&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;2. Eliminate unnecessary meetings&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Face-to-face communication is essential (email is fraught with misinterpretation), but be ruthless about protecting your time. Avoid every meeting that isn’t truly necessary.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;3. Learn how to say ‘no’&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;While everyone wants to be a good team player at work, saying ‘no’ is sometimes the right thing to do. If you are not the best person for a task, or if you have other pending deadlines, it is OK to turn down a work request.&amp;nbsp; &lt;a href=&quot;http://blog.bayt.com/2014/01/12-ways-to-improve-your-productivity-at-work/&quot;&gt;read more&lt;/a&gt;&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/6103009088721486099/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/12-ways-to-improve-your-productivity-at.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6103009088721486099'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6103009088721486099'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/12-ways-to-improve-your-productivity-at.html' title='12 Ways to Improve Your Productivity at Work'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEin5T1XmNxfbC_jXIHcCeUD_t7tdaAYAlJqMz-rD5VsUuppRVtv-AmQgp0DceBO22T1ToVHP8hlcIjehky-4UyC5zEJXrZuLywR5KCNg4qHNajeVXLNGgpWk1DECrRR7FglqKOelF-b6LNN/s72-c?imgmax=800" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-6556145577554457695</id><published>2014-11-11T16:46:00.001+03:00</published><updated>2014-11-11T16:46:00.605+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Development"/><category scheme="http://www.blogger.com/atom/ns#" term="X++"/><title type='text'>How to reset TTSBegin/TTSCommit in AX</title><content type='html'>&lt;p&gt;We are using TTSBegin and TTSCommit when update and create a record in AX, but some times an error is occurred&amp;nbsp; and through an exception.&lt;/p&gt; &lt;p&gt;If we did not abort TTS by using TTSAbort&amp;nbsp; statement between try and catch keyword as below&lt;/p&gt; &lt;p&gt;try&lt;/p&gt; &lt;p&gt;{&lt;/p&gt; &lt;p&gt;ttsBegin;&lt;/p&gt; &lt;p&gt;// your update code&lt;/p&gt; &lt;p&gt;ttsCommit;&lt;/p&gt; &lt;p&gt;}&lt;/p&gt; &lt;p&gt;catch&lt;/p&gt; &lt;p&gt;{&lt;/p&gt; &lt;p&gt;ttsAbort;&lt;/p&gt; &lt;p&gt;}&lt;/p&gt; &lt;p&gt;so we may facing this error below,&lt;/p&gt; &lt;p&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh816jwM-7s_egRbfd7go4Ei6QKonrooaatM1Ph7yGYmWyXhB5VKW-NucbNkiujgHSdTprKMhG2K6f_SwhMskaDiQANnLQ_02GOQWwDgrL88lXshajLv_f1iL24xULzAa2rq-AqyCA-yjk/s1600/ttsbeign+error.png&quot; width=&quot;314&quot; height=&quot;177&quot;&gt;&lt;/p&gt; &lt;p&gt;To fix this error please run the following job&lt;/p&gt; &lt;p&gt;static void ResetTTS(Args _args) &lt;br&gt;{ &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; while (appl.ttsLevel() &amp;gt; 0) &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; { &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; info(strfmt(&quot;Level %1 aborted&quot;,appl.ttsLevel())); &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ttsAbort; &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; } &lt;br&gt;}&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/6556145577554457695/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/how-to-reset-ttsbeginttscommit-in-ax.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6556145577554457695'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6556145577554457695'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/how-to-reset-ttsbeginttscommit-in-ax.html' title='How to reset TTSBegin/TTSCommit in AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh816jwM-7s_egRbfd7go4Ei6QKonrooaatM1Ph7yGYmWyXhB5VKW-NucbNkiujgHSdTprKMhG2K6f_SwhMskaDiQANnLQ_02GOQWwDgrL88lXshajLv_f1iL24xULzAa2rq-AqyCA-yjk/s72-c/ttsbeign+error.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-8124392069160914928</id><published>2014-11-10T14:20:00.001+03:00</published><updated>2014-11-10T14:20:38.875+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Development"/><title type='text'>Make sure that the X++ code has been compiled to Microsoft .NET Framework CIL - AX Batch Error</title><content type='html'>&lt;p&gt;I developed custom class which extend RunBaseBatch system class to run in server, After created my class and run the class though batch job, there is an error is occurred and got the following error in log.&lt;/p&gt; &lt;p&gt;&quot;&lt;em&gt;Unable to construct an object from the class Sample Class in the batch framework. Make sure that the X++ code has been compiled to Microsoft .NET Framework CIL, and that the constructor does not require any parameters&lt;/em&gt;&quot;&lt;/p&gt; &lt;p&gt;After search through internet I got solution by run “Generate incremental CIL” as&amp;nbsp; displayed below&lt;/p&gt; &lt;p&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEifnn9W7l_qyoqZ_WIsQK4J8miQqwevP9DehL6mGGhZ2VVhtpWfECoX4x9cm3iBct9BxPT34jAc4wGo5vPuccsfi2t-raePs-c2AHUXwHtne4gObD1Eap5dpVEj5AnXHf7POrsr3EWs9QcK/s1600-h/image%25255B3%25255D.png&quot;&gt;&lt;img title=&quot;image&quot; style=&quot;border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; border-left: 0px; display: inline; padding-right: 0px&quot; border=&quot;0&quot; alt=&quot;image&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEikmjhmICxbevtim41Wi0x-pY4zLhUyW1ghGCVILN2H71NxQYAJdwPkC5MEK8XZpBgQHmHxJaEchu2yx1Y1yQTbREnp9hzrdgL3UOg2YTBR6pOpgdY9BUMp5j0fbsyf_x8Vm2a9rNzSaHAz/?imgmax=800&quot; width=&quot;296&quot; height=&quot;249&quot;&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Hint: May it takes time depend on server configuration.&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/8124392069160914928/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/make-sure-that-x-code-has-been-compiled.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/8124392069160914928'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/8124392069160914928'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/make-sure-that-x-code-has-been-compiled.html' title='Make sure that the X++ code has been compiled to Microsoft .NET Framework CIL - AX Batch Error'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEikmjhmICxbevtim41Wi0x-pY4zLhUyW1ghGCVILN2H71NxQYAJdwPkC5MEK8XZpBgQHmHxJaEchu2yx1Y1yQTbREnp9hzrdgL3UOg2YTBR6pOpgdY9BUMp5j0fbsyf_x8Vm2a9rNzSaHAz/s72-c?imgmax=800" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-1628627341919957603</id><published>2014-11-09T12:00:00.001+03:00</published><updated>2014-11-09T12:00:09.157+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Dynamics AX"/><title type='text'>Performance considerations for number sequences in Dynamics AX</title><content type='html'>&lt;h5&gt; &lt;h4&gt;&lt;font style=&quot;font-weight: normal&quot;&gt;&lt;font color=&quot;#000000&quot; size=&quot;2&quot;&gt;Consider the following information about how the configuration of number sequences can affect system performance before you set up number sequences.&lt;/font&gt; &lt;/font&gt;&lt;/h4&gt; &lt;p&gt;&lt;font size=&quot;4&quot;&gt;Continuous and non-continuous number sequences&lt;/font&gt;&lt;/p&gt;&lt;/h5&gt; &lt;p&gt;Number sequences can be continuous or non-continuous. A continuous number sequence does not skip any numbers, but numbers may not be used sequentially. Numbers from a non-continuous number sequence are used sequentially, but the number sequence may skip numbers. For example, if a user cancels a transaction, a number is generated, but not used. In a continuous number sequence, that number is recycled later. In a non-continuous number sequence, the number is not used. &lt;/p&gt; &lt;p&gt;Continuous number sequences are typically required for external documents, such as purchase orders, sales orders, and invoices. However, continuous number sequences can adversely affect system response times because the system must request a number from the database every time that a new document or record is created. &lt;/p&gt; &lt;p&gt;If you use a non-continuous number sequence, you can enable &lt;strong&gt;Preallocation&lt;/strong&gt; on the &lt;strong&gt;Performance&lt;/strong&gt; FastTab of the &lt;strong&gt;Number sequences&lt;/strong&gt; form. When you specify a quantity of numbers to preallocate, the system selects those numbers and stores them in memory. New numbers are requested from the database only after the preallocated quantity has been used. &lt;/p&gt; &lt;p&gt;Unless there is a regulatory requirement that you use continuous number sequences, we recommend that you use non-continuous number sequences for better performance. &lt;/p&gt; &lt;h5&gt; &lt;p&gt;&lt;strong&gt;&lt;font size=&quot;4&quot;&gt;Automatic cleanup of number sequences&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;&lt;/h5&gt; &lt;p&gt;&lt;a&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;In case of a power failure, an application error, or other unexpected failure, the system cannot recycle numbers automatically for continuous number sequences. You can run the cleanup process manually or automatically to recover the lost numbers. &lt;/p&gt; &lt;p&gt;Carefully consider server usage when you plan the cleanup process. We recommend that you perform the cleanup as a batch job during non-peak hours. &lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/1628627341919957603/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/performance-considerations-for-number.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/1628627341919957603'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/1628627341919957603'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/performance-considerations-for-number.html' title='Performance considerations for number sequences in Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-3605420422616309544</id><published>2014-11-05T11:48:00.001+03:00</published><updated>2014-11-05T11:48:49.026+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Development"/><category scheme="http://www.blogger.com/atom/ns#" term="X++"/><title type='text'>How to pass parameter to SSRS report from Dynamics AX</title><content type='html'>&lt;p&gt;The below code for Passing parameters to SSRS using X++ code.&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; MenuFunction SSRS_MyReport;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Args Args;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; str parmId =&quot;&quot;;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp; // create reference to menu item “OverTime” which is in AOT&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; SSRS_MyReport = new MenuFunction(menuItemOutputStr(OverTime),MenuItemType::Output);&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Args = new Args();&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Set parameters and parameter value&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; // I have 3 Parameters Nationality, EmplGroup, PeriodID&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; parmId = &quot;Nationality=KSA&amp;amp;EmplGroup=HERD&amp;amp;PeriodID=2014_05&quot;;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Assign parameters to report&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Args.parm(parmId);&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Run the report&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; SSRS_MyReport.run(Args);&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;Notes:&lt;/p&gt; &lt;p&gt;1- Parameters name is case sensitive, so it should set name as predefined in report.&lt;/p&gt; &lt;p&gt;2- You can pass more than one parameters by add “&amp;amp;”&amp;nbsp;&amp;nbsp; between each parameter.&lt;/p&gt; &lt;p&gt;3- Not add space between parameters, it cause an error&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/3605420422616309544/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/how-to-pass-parameter-to-ssrs-report.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/3605420422616309544'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/3605420422616309544'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/how-to-pass-parameter-to-ssrs-report.html' title='How to pass parameter to SSRS report from Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-6545834570071632745</id><published>2014-11-04T10:07:00.001+03:00</published><updated>2014-11-04T10:07:06.027+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX Administration"/><category scheme="http://www.blogger.com/atom/ns#" term="Dynamics AX"/><title type='text'>Recalculation Error Dynamics AX 2009</title><content type='html'>&lt;p&gt;while running inventory recalculation process, I got this error &lt;/p&gt; &lt;p&gt;“Cannot edit a record in stock transactions (InventTrans) An update&lt;br&gt;conflict occurred due to another user process deleting the record or changing&lt;br&gt;one or more fields in the record&quot;&lt;/p&gt; &lt;p&gt;solution to avoid this error, go to AOT –&amp;gt; DataDictionary –&amp;gt; Tables ----&amp;gt; InventTrans &lt;/p&gt; &lt;p&gt;right click on table to display properties window then change OccEnabled property to No.&lt;/p&gt; &lt;p&gt;then resume recalculation again, it will work successfully.&lt;/p&gt; &lt;p&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi101qyCC1HBEn5k1Q_inu2-qwfgmS0DQ7hH9Uhcqs5eQGH4UkzwwCQECsyQQLiu3VlNLwjsBDQLf7hgLk3G5EDG2FqDUdH0iVRtEK8KZX46pDbo1B2O1pQy6qO2opWr3QYszwIvvne1w2B/s1600-h/image%25255B2%25255D.png&quot;&gt;&lt;img title=&quot;image&quot; style=&quot;border-top: 0px; border-right: 0px; background-image: none; border-bottom: 0px; padding-top: 0px; padding-left: 0px; margin: 0px; border-left: 0px; display: inline; padding-right: 0px&quot; border=&quot;0&quot; alt=&quot;image&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipyBjfI2KfxDvyxnRqJq6Xs3i39zc868SggGXdTNJ50SJHWLtpQOGYCwKk-a9IWz-7CRqZcNivnjE07emvxtEuKZnWwixRWXyquJHz8Te90yZiX2zeWSBj36z37I4q97saKN5ctH5vMxeW/?imgmax=800&quot; width=&quot;244&quot; height=&quot;158&quot;&gt;&lt;/a&gt;&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/6545834570071632745/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/recalculation-error-dynamics-ax-2009.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6545834570071632745'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6545834570071632745'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/recalculation-error-dynamics-ax-2009.html' title='Recalculation Error Dynamics AX 2009'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipyBjfI2KfxDvyxnRqJq6Xs3i39zc868SggGXdTNJ50SJHWLtpQOGYCwKk-a9IWz-7CRqZcNivnjE07emvxtEuKZnWwixRWXyquJHz8Te90yZiX2zeWSBj36z37I4q97saKN5ctH5vMxeW/s72-c?imgmax=800" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-6741625510540251042</id><published>2014-11-02T09:37:00.001+03:00</published><updated>2014-11-02T09:37:53.723+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX Administration"/><category scheme="http://www.blogger.com/atom/ns#" term="SQL"/><title type='text'>Configuring the instance of SQL Server for Dynamics AX</title><content type='html'>&lt;p&gt;Improve SQL performance lead us to optimize AX performance, this post is one of posts to achieve that &lt;/p&gt; &lt;p&gt;&lt;b&gt;1- Configuring max degree of parallelism&lt;/b&gt; &lt;/p&gt; &lt;p&gt;The &lt;b&gt;max degree of parallelism&lt;/b&gt; option is a setting that affects the entire instance of SQL Server. Microsoft Dynamics AX workloads generally perform better when intra-query parallelism is disabled. However, the upgrade process benefits from parallelism, as do activities that are used exclusively for batch jobs or maintenance. Use the following settings when the system performs maintenance activities or an upgrade: &lt;/p&gt; &lt;p&gt;· Before an upgrade to a new release of Microsoft Dynamics AX, or before a large number of maintenance or batch activities, set &lt;b&gt;max degree of parallelism&lt;/b&gt; to the smallest of the following values: &lt;/p&gt; &lt;p&gt;· 8 &lt;/p&gt; &lt;p&gt;· The number of physical processor cores &lt;/p&gt; &lt;p&gt;· The number of physical processor cores per non-uniform memory access (NUMA) node &lt;/p&gt; &lt;p&gt;· When the Microsoft Dynamics AX database is used in a production environment, set &lt;b&gt;max degree of parallelism&lt;/b&gt; to 1. &lt;/p&gt; &lt;p&gt;Use the following statements to set the value of &lt;b&gt;max degree of parallelism&lt;/b&gt;. &lt;/p&gt; &lt;p&gt;Examine the output from the second sp_configure &#39;max degree of parallelism&#39; statement, and confirm that the value has been changed. In the following query, the first sp_configure &#39;max degree of parallelism&#39; statement sets the value of &lt;b&gt;max degree of parallelism&lt;/b&gt; to 1. The second sp_configure &#39;max degree of parallelism&#39; statement returns a value of 1. &lt;/p&gt; &lt;p&gt;EXEC sp_configure &#39;show advanced options&#39;, 1; &lt;/p&gt; &lt;p&gt;RECONFIGURE; &lt;/p&gt; &lt;p&gt;GO &lt;/p&gt; &lt;p&gt;EXEC sp_configure &#39;max degree of parallelism&#39;, 1; &lt;/p&gt; &lt;p&gt;RECONFIGURE; &lt;/p&gt; &lt;p&gt;GO &lt;/p&gt; &lt;p&gt;EXEC sp_configure; &lt;/p&gt; &lt;p&gt;For more information, see &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=213211&quot;&gt;max degree of parallelism Option&lt;/a&gt;. For general guidelines, see Knowledge base article 329204, &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=213212&quot;&gt;General guidelines to use to configure the MAXDOP option&lt;/a&gt;. For tips from the SQL Server team, visit the SQL Server Relational Engine team&#39;s blog, &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=213213&quot;&gt;SQL Server Engine Tips&lt;/a&gt;. &lt;/p&gt; &lt;p&gt;&lt;b&gt;2- Configuring max server memory&lt;/b&gt; &lt;/p&gt; &lt;p&gt;SQL Server dynamically acquires and frees memory as required. Typically, an administrator does not have to specify how much memory is allocated to SQL Server. However, the &lt;b&gt;max server memory&lt;/b&gt; option can be useful in some environments. Make sure that sufficient memory is available for the operation of Windows Server. For more information, see &lt;a href=&quot;http://technet.microsoft.com/EN-US/library/dd309734.aspx#Section5_monitor&quot;&gt;Configure SQL Server and storage settings&lt;/a&gt;, later in this topic. &lt;/p&gt; &lt;p&gt;If you find that the dynamic allocation of memory adversely affects the operation of Windows Server, adjust the value of &lt;b&gt;max server memory&lt;/b&gt; based on the available random access memory (RAM). For more information, see &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=213214&quot;&gt;Effects of min and max server memory&lt;/a&gt;. &lt;/p&gt; &lt;p&gt;&lt;b&gt;3- Monitoring available memory&lt;/b&gt; &lt;/p&gt; &lt;p&gt;Make sure that sufficient memory is available for the operation of Windows Server. For example, make sure that you run a dedicated instance of SQL Server on a server that has at least 4 gigabytes (GB) of memory. If the available memory for the server drops below 500 megabytes (MB) for extended periods, the performance of the server may degrade. &lt;/p&gt; &lt;p&gt;Use the &lt;b&gt;Memory: Available Mbytes&lt;/b&gt; performance counter for the Windows Server operating system to determine whether the available memory drops below 500 MB for extended periods. If the available memory drops below 500 MB frequently or for extended periods, we recommend that you reduce the &lt;b&gt;max server memory&lt;/b&gt; setting for SQL Server or increase the physical memory of the server. &lt;/p&gt; &lt;p&gt;Detailed guidance about memory management is beyond the scope of this topic. For more information about how to monitor memory and troubleshoot performance issues, see the Windows Server and SQL Server documentation. &lt;/p&gt; &lt;p&gt;&lt;b&gt;4- Allocating storage for tempdb&lt;/b&gt; &lt;/p&gt; &lt;p&gt;We recommend that you determine the total size of the data files and transaction log files that are required for the tempdb database, and that you set a specific value. Do not use automatic growth, or autogrow, setting for space management. Instead, use autogrow as a safety mechanism, so that tempdb can grow if tempdb files use the space that was originally allocated to them. Follow this process to determine the number and placement of data files. &lt;/p&gt; &lt;p&gt;· Determine the number of processors that are available to SQL Server. Unless you are using an affinity mask, this number is same as the total number of processors that you see on the &lt;b&gt;Performance&lt;/b&gt; tab of Windows Task Manager. When hyperthreading is not enabled, each processor corresponds to a processor core. Affinity masks and processor cores are beyond the scope of this topic. For more information, see the Windows Server and SQL Server documentation. &lt;/p&gt; &lt;p&gt;· Based on performance testing of the OLTP workload for Microsoft Dynamics AX, we recommend that you maintain one tempdb data file per processor. For more information, see the performance benchmark reports on &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=143994&quot;&gt;PartnerSource&lt;/a&gt; or &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=213216&quot;&gt;CustomerSource&lt;/a&gt;. &lt;/p&gt; &lt;p&gt;· Isolate tempdb on dedicated storage, if you can. We recommend that you move the primary data file and log file for tempdb to high-speed storage, if high-speed storage is available. The Microsoft Dynamics AX database runs in read committed snapshot isolation (RCSI) mode. In RCSI mode, row versions are stored in tempdb. By creating multiple files for tempdb data, even if these files reside on the same storage device, you can improve the performance of tempdb operations. &lt;/p&gt; &lt;p&gt;· Determine the size of the tempdb data files and log files. You must create one primary data file and one log file. Determine how many additional, secondary data files you require for the tempdb data. For best results, create data files of equal size. The total number of data files must equal the total number of processor cores. The aggregate size of the primary data file and all other data files must equal the total data size that you determined for the tempdb database. &lt;/p&gt; &lt;p&gt;For more information, see &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=213217&quot;&gt;Optimizing tempdb performance&lt;/a&gt;. &lt;/p&gt; &lt;p&gt;· Resize the primary data file and log file for tempdb. Move the primary data file and log file to dedicated storage, if dedicated storage is available. The primary tempdb data file cannot be moved while the instance of SQL Server is running. To complete the move, you must use an ALTER DATABASE statement and restart the instance of SQL Server. For more information, see &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=213218&quot;&gt;ALTER DATABASE&lt;/a&gt;. &lt;/p&gt; &lt;p&gt;&lt;b&gt;Note: &lt;/b&gt;The data files and transaction log files for tempdb can reside on the same storage device. &lt;/p&gt; &lt;p&gt;· If space is available on the drive where tempdb files are allocated, do not configure the autogrow property for data files and log files as a percentage. Instead, configure the autogrow property as a specific number of megabytes. If you can, configure the data files and log files to grow by 100 to 500 MB, depending on the available space. Monitor the data files, and when they grow, adjust the original allocation to prevent automatic growth later. If the autogrow property is configured in megabytes instead of as a percentage, the allocation of space is more predictable, and the chance of extremely small or large growth increments is reduced. &lt;/p&gt; &lt;p&gt;· Monitor the tempdb data files and log files to make sure that they are all sized correctly, and that all data files are of equal size. Use SQL Server Management Studio or a transact-SQL query to view the database properties. Verify that all the data files are of equal size, and that they have the same size as the value that you originally provided. If one or more files have grown, adjust the initial size of all files.&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/6741625510540251042/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/configuring-instance-of-sql-server-for.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6741625510540251042'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6741625510540251042'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/11/configuring-instance-of-sql-server-for.html' title='Configuring the instance of SQL Server for Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-5683976572033579959</id><published>2014-10-27T17:02:00.001+03:00</published><updated>2014-10-27T17:02:30.877+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX Administration"/><category scheme="http://www.blogger.com/atom/ns#" term="SQL"/><title type='text'>Configuring physical storage for SQL server of Dynamics AX</title><content type='html'>&lt;p&gt;This post provides general recommendations for physical storage. Determine the applicability of these recommendations to your environment. Some storage area network (SAN) vendors may have alternative recommendations that take precedence. Recommendations are listed in order of priority. &lt;ul&gt; &lt;li&gt;· Many factors contribute to optimal I/O performance for a disk. By default, Windows Server 2008 aligns partitions. When you upgrade to Windows Server 2008, preexisting partitions are not automatically aligned and must be manually rebuilt to guarantee optimal performance. Therefore, until you rebuild the migrated partitions, alignment of disk partitions remains a relevant technology.&lt;/li&gt; &lt;li&gt;Check existing disks on the server, and be aware of the differences in the analysis of basic partitions and dynamic volumes. Rebuild the partitions, if you can, and appropriate and create all new partitions based on guidance from the SAN vendor. If the vendor does not provide recommendations, follow the best practices for SQL Server. See &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=213222&quot;&gt;Disk Partition Alignment Best Practices for SQL Server&lt;/a&gt;.&lt;/li&gt; &lt;li&gt;The partition offset value must be a multiple of the stripe size. In other words, the expression, &lt;em&gt;partition offset / stripe size&lt;/em&gt;, must resolve to an integer value.&lt;/li&gt; &lt;li&gt;· Create the tempdb database files, data files for the Microsoft Dynamics AX database, and Microsoft Dynamics AX log files on disk arrays of type RAID 1, RAID 0 + 1, or RAID 10. We recommend RAID 10 for these files. Do not use RAID 5.&lt;/li&gt; &lt;li&gt;· Store the data files for the Microsoft Dynamics AX database on separate physical stores from the transaction log files.&lt;/li&gt; &lt;li&gt;· Store the tempdb data files on a separate physical store from the data files and log files for the Microsoft Dynamics AX database.&lt;/li&gt; &lt;li&gt;· Store other database files on separate physical stores from the data files and log files for tempdb and the Microsoft Dynamics AX database.&lt;/li&gt;&lt;/ul&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/5683976572033579959/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/10/configuring-physical-storage-for-sql.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/5683976572033579959'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/5683976572033579959'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/10/configuring-physical-storage-for-sql.html' title='Configuring physical storage for SQL server of Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-682299308556148345</id><published>2014-10-26T14:00:00.001+03:00</published><updated>2014-10-26T14:00:41.015+03:00</updated><title type='text'>Tune data access settings [AX 2012]</title><content type='html'>&lt;p&gt;You might want to tune the database settings for Microsoft Dynamics AX to improve performance. Settings that you can tune &lt;i&gt;include connections, query settings for the use of literals, string functions, or hints, concurrency mode used for database changes, and the table and index options, such as table and index data compression, and index fill factor and sort in tempdb settings&lt;/i&gt;. &lt;/p&gt; &lt;p&gt;Before changing settings, you should trace the usage of your Microsoft Dynamics AX database to ensure that you have clear understanding of performance under the current settings. &lt;/p&gt; &lt;p&gt;Test all tuning changes before implementing them in a production environment. In a test or development environment, make a single change and then test your system&#39;s performance before making another change. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Tune connections &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;The following table lists common connection issues, and also some adjustments to try in the &lt;b&gt;Server Configuration Utility&lt;/b&gt;.  &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Symptom&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Adjustments to try&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Queries that return a large number of rows execute slowly.&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Increase the &lt;b&gt;Maximum buffer size&lt;/b&gt; value in small increments. &lt;/p&gt; &lt;p&gt;If this adjustment has worked, the number of round trips to the database, as measured in Performance Monitor by a decrease in the value of &lt;strong&gt;SQL Server statistics: batchrequestsPerSecond&lt;/strong&gt; value. Stop increasing the value when the rate of improvement diminishes. &lt;/p&gt; &lt;p&gt;You may also want to change the &lt;b&gt;Maximum buffer size&lt;/b&gt; value if you receive an error similar to the following: &lt;/p&gt; &lt;p&gt;&lt;strong&gt;The total, internal size of the records in your joined Select statement is 29374 bytes, but Microsoft Dynamics is by default performance-tuned not to exceed 27646 bytes. It is strongly recommended that you split your tables(s) into smaller units.&lt;/strong&gt; &lt;/p&gt; &lt;p&gt;Maximum buffer size refers to the size of buffer the kernel allocates for holding input/output data to and from SQL Server. The buffer can be used to hold more than one row of the entire result set for output binding, and it should be allocated large enough to hold at least one row. The buffer size needed for one row depends on the number of tables joined (exist join excluded) and the size of the aggregated table columns. When large numbers of joins are used, or wide tables, a customer may encounter the issue that the maximum buffer size is less than the space needed to hold one row of the result set. &lt;/p&gt; &lt;p&gt;Due to the way the kernel handles data binding, the aggregated table column size is always the width of the entire table. Therefore, attempting to resolve the issue by limiting the field projection list does not help. You can fix the issue by rewriting the join, or by increasing the &lt;b&gt;Maximum buffer size&lt;/b&gt; value. &lt;/p&gt; &lt;p&gt;Because large joins and wide rows may lead to performance issues, we use this limit to catch performance issues and ask customers to rethink their joins.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Results for ad hoc queries are returned slowly&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Verify that the appropriate indexes are in place.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Tune queries &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;If queries in the system are running slowly, you may want to change settings for literals, string functions, or hints. &lt;/p&gt; &lt;p&gt;&lt;br&gt;&lt;strong&gt;Adjust the use of hints &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;In Microsoft Dynamics AX, you can allow developers to override the index selected by the query optimizer. In most situations, allowing the query optimizer to select an index for a query results in improved performance. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Changes in the use of hints &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;The following changes to hints have been made: &lt;/p&gt; &lt;p&gt;· The OPTION (FIRSTFAST) hint is applied by default for form data sources. It can be suppressed, or set to a specific value. Use of this option appends an OPTION (FAST) to the SQL Server query. &lt;/p&gt; &lt;p&gt;· OPTION( FAST) is now set to what we expect the number of rows to be returned to the database in a single roundtrip. This is based on maximum buffer size. &lt;/p&gt; &lt;p&gt;· FASTFORWARD cursors are used for all user queries unless the query is a full text search. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Change table and index options&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Table and index options that can be changed from within Microsoft Dynamics AX include table compression settings, and index compression, fill factor, and sort in tempdb settings. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Data compression options&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;If you have appropriate hardware, we recommend that you set all tables and indexes to use page-level compression. Compression saves disk space and memory consumption, but increases CPU consumption. &lt;/p&gt; &lt;p&gt;When page-level compression has been set, expect between 10-15 percent additional CPU consumption. &lt;/p&gt; &lt;p&gt;If you are concerned about CPU consumption, we recommend that you start by setting the ten largest tables in your system to use table compression. &lt;/p&gt; &lt;p&gt;Use the guidance in the following resources to help you determine how or whether to compress your tables and indexes: &lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;· SQL Server Books online: &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=210430&quot;&gt;Creating Compressed Tables and Indexes&lt;/a&gt; &lt;/p&gt; &lt;p&gt;· SQLCat article: &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=210431&quot;&gt;Data Compression: Strategy, Capacity Planning and Best Practices&lt;/a&gt; &lt;/p&gt; &lt;p&gt;· Database Engine team blog post: &lt;a href=&quot;http://go.microsoft.com/fwlink/?LinkId=210424&quot;&gt;Compression Strategies&lt;/a&gt;.&amp;nbsp;&amp;nbsp; &lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;&lt;strong&gt;Fill factor options&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;We recommend that you not set the fill factor options (fill factor and pad index) for all indexes. Only set fill factor values on indexes that show rapid fragmentation, where fragmentation has a performance penalty. Adjusting fill factor can be important for tables that you want to retrieve sequential rows from, for example, sales line. &lt;/p&gt; &lt;p&gt;We recommend that you work with your database administrators to identify the tables to set this value for. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Sort in tempdb&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;We recommend that you not set the sort in tembdp options for all indexes. Only enable sort in tempdb for indexes that show rapid fragmentation, where fragmentation has a performance penalty. &lt;/p&gt; &lt;p&gt;We recommend that you work with your database administrators to identify the tables to set this value for. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;To change table and index options&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;1. Click &lt;b&gt;System administration&lt;/b&gt; &amp;gt; &lt;b&gt;Periodic&lt;/b&gt; &amp;gt; &lt;b&gt;Database&lt;/b&gt; &amp;gt; &lt;b&gt;SQL administration&lt;/b&gt;. Select all tables, all indexes, or a specific table or index, and then click &lt;b&gt;Table and index options&lt;/b&gt;. &lt;/p&gt; &lt;p&gt;2. Select the options to set, and then click &lt;b&gt;Save&lt;/b&gt;. &lt;/p&gt; &lt;p&gt;The SQL statement that will be executed is displayed at the bottom of the form.  &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjECAs5P2oeaPB7QRbHUKQS-t8sTOVjTO2gFlMFEyFUScpwAHkU7tZTynKAuNH-Tu28urxbNAj1auoQdqzhtcmgWhx-nFjg8xDRq8USWJqgiFPydWUsvMZbCm7STMDVFkSB7wyAkwfh8Rjq/s1600-h/clip_image001%25255B3%25255D.gif&quot;&gt;&lt;img title=&quot;clip_image001&quot; style=&quot;border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px&quot; border=&quot;0&quot; alt=&quot;clip_image001&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEikBdLWzA7zebU8HTq3FmTrA_zH0LT-o0zNj1peTAPmvoaQA7w-x2tOvWLTZe_M6M6pIlS7DN3HEuZHGrcqZzPnyVfGFESTErbjSLRMkdfcycp_0eTQl0wlbwhn3B5ozmjcPOD3GJtQL4Qy/?imgmax=800&quot; width=&quot;2&quot; height=&quot;2&quot;&gt;&lt;/a&gt;&lt;/b&gt;&lt;b&gt;Important&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The changes that you have made will not be applied unless you specify that they should be applied by using the &lt;b&gt;SQL administration&lt;/b&gt; form. &lt;/p&gt; &lt;p&gt;To turn off data compression, click &lt;b&gt;Enable compression&lt;/b&gt;, click &lt;b&gt;None&lt;/b&gt; for the type of compression, and then close the &lt;b&gt;Select table and index options&lt;/b&gt; form, and then click &lt;b&gt;Apply compression&lt;/b&gt; in the &lt;b&gt;SQL administration&lt;/b&gt; form.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt; &lt;p&gt;3. To apply changes in the &lt;b&gt;SQL administration&lt;/b&gt; form: &lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;o For tables, click &lt;b&gt;Table actions&lt;/b&gt;, and then click &lt;b&gt;Apply compression&lt;/b&gt;. &lt;/p&gt; &lt;p&gt;o For indexes, click &lt;b&gt;Index actions&lt;/b&gt;, and then click &lt;b&gt;Reindex&lt;/b&gt;. &lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;&lt;strong&gt;Change the concurrency mode&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Concurrency mode settings enable you to reduce locking conflicts in your system. Set concurrency mode settings only at the table or statement level, not throughout your Microsoft Dynamics AX program. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Optimistic concurrency&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;An optimistic concurrency strategy does not lock data when the data is retrieved from the database for future modification. Therefore, no locks are held while filters and other business logic are being applied. Data is locked only when an update is performed. If any data has been changed by another transaction between the time of the retrieval and the time of the update, the change is detected and an Infolog exception is displayed. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Pessimistic concurrency&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;A pessimistic concurrency strategy uses an update lock to lock data when the data is retrieved from the database for future modification. Locks are held while filters and other business logic are being applied, in addition to being held during an update. Data cannot be changed by other transactions. &lt;/p&gt; &lt;p&gt;Acquiring an update lock for a large volume of rows increases the lock escalation from row level to table level in SQL Server. This can block other users and reduce transaction throughput. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Table-level concurrency settings&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;If the global concurrency mode is set to &lt;b&gt;Optimistic concurrency mode enabled per table&lt;/b&gt;, table-level control of concurrency settings is available using the &lt;b&gt;OccEnabled&lt;/b&gt; property. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Runtime update options&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;If you are encountering many update errors, you may want to use the runtime update options to help troubleshoot. These options are intended for temporary use only, as they might significantly slow performance. &lt;/p&gt; &lt;p&gt;Use &lt;b&gt;Writes all UPDATE conflict exceptions to the log&lt;/b&gt; to write all update conflict exceptions to the log. &lt;/p&gt; &lt;p&gt;Use &lt;b&gt;Update record version automatically&lt;/b&gt; to have Microsoft Dynamics AX search in memory for the recordID every time that that a record is updated, and then change the update values in all instances of the record. &lt;/p&gt; &lt;p&gt;If you have a table set to optimistic concurrency, and you are experiencing optimistic concurrency violations that affect the performance of the transactions that use the table, then first set the &lt;b&gt;Writes all UPDATE conflict exceptions to the log&lt;/b&gt; option. If, from your analysis, it appears that the use of optimistic concurrency is causing a problem, then set the table to pessimistic concurrency. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;To change concurrency settings &lt;/strong&gt;&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;1. Click &lt;b&gt;System administration&lt;/b&gt; &amp;gt; &lt;b&gt;Setup&lt;/b&gt; &amp;gt; &lt;b&gt;Database&lt;/b&gt; &amp;gt; &lt;b&gt;Select concurrency mode&lt;/b&gt;. &lt;/p&gt; &lt;p&gt;2. Select the appropriate concurrency mode and runtime options for your environment. &lt;/p&gt; &lt;p&gt;3. Click &lt;b&gt;Close&lt;/b&gt;. &lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;&lt;strong&gt;Statement-level concurrency settings&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;You can use the &lt;b&gt;optimisticlock&lt;/b&gt; or &lt;b&gt;pessimisticlock&lt;/b&gt; keywords in a SELECT statement to override the global or table concurrency mode settings. &lt;/p&gt; &lt;p&gt;For more information, see the following topics: &lt;/p&gt; &lt;p&gt;· &lt;a href=&quot;http://technet.microsoft.com/en-us/library/aa854605.aspx&quot;&gt;Best Practice Performance Optimizations: Database Design and Operations&lt;/a&gt; &lt;/p&gt; &lt;p&gt;· &lt;a href=&quot;http://technet.microsoft.com/en-us/library/aa622564.aspx&quot;&gt;Transaction Integrity&lt;/a&gt; &lt;/p&gt; &lt;p&gt;· &lt;a href=&quot;http://technet.microsoft.com/en-us/library/aa893385.aspx&quot;&gt;Exception Handling with try and catch Keywords&lt;/a&gt; &lt;/p&gt; &lt;p&gt;· &lt;a href=&quot;http://technet.microsoft.com/en-us/library/aa656402.aspx&quot;&gt;Select Statement Syntax&lt;/a&gt; &lt;/p&gt; &lt;p&gt;· &lt;a href=&quot;http://technet.microsoft.com/en-us/library/aa871620.aspx&quot;&gt;Table Properties&lt;/a&gt;&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/682299308556148345/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/10/tune-data-access-settings-ax-2012.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/682299308556148345'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/682299308556148345'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/10/tune-data-access-settings-ax-2012.html' title='Tune data access settings [AX 2012]'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEikBdLWzA7zebU8HTq3FmTrA_zH0LT-o0zNj1peTAPmvoaQA7w-x2tOvWLTZe_M6M6pIlS7DN3HEuZHGrcqZzPnyVfGFESTErbjSLRMkdfcycp_0eTQl0wlbwhn3B5ozmjcPOD3GJtQL4Qy/s72-c?imgmax=800" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-6192773848233110823</id><published>2014-09-30T14:32:00.001+03:00</published><updated>2014-09-30T14:32:17.213+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX Administration"/><title type='text'>Uninstall Microsoft Dynamics AX</title><content type='html'>&lt;p&gt;This topic explains how to uninstall Microsoft Dynamics AX by using &lt;b&gt;Add or Remove Programs&lt;/b&gt; on the Control Panel.  &lt;p&gt;Databases, log files, and application files must be removed manually. Information about how to manually remove components is also included in this topic.  &lt;p&gt;&lt;strong&gt;Uninstall components by using Add or Remove Programs&lt;/strong&gt;  &lt;p&gt;Use this procedure to remove Microsoft Dynamics AX components.  &lt;ol&gt; &lt;li&gt;Open &lt;b&gt;Add or Remove Programs&lt;/b&gt;. (&lt;b&gt;Start&lt;/b&gt; &amp;gt; &lt;b&gt;All Programs&lt;/b&gt; &amp;gt; &lt;b&gt;Control Panel&lt;/b&gt; &amp;gt; &lt;b&gt;Add or Remove Programs&lt;/b&gt;).  &lt;li&gt;Select the component that you want to remove, and then click &lt;b&gt;Remove&lt;/b&gt;. The components that are listed in the following table can be removed.&lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Option&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Removes&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Microsoft Dynamics AX Components&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Selecting this option removes the following components:  &lt;p&gt;o Client  &lt;p&gt;o Role Centers and the Enterprise Portal framework  &lt;p&gt;o Workflow  &lt;p&gt;o Reporting extensions  &lt;p&gt;o Debugger  &lt;p&gt;o Enterprise Portal developer tools  &lt;p&gt;o Reporting tools  &lt;p&gt;o .NET Business Connector  &lt;p&gt;o AIF Web services  &lt;p&gt;o BizTalk adapter  &lt;p&gt;o Synchronization proxy for Microsoft Office Project  &lt;p&gt;o Synchronization service for Microsoft Office Project  &lt;p&gt;This option removes all components that are installed on the local computer. You cannot select to remove individual components.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Microsoft Dynamics AX Client Help Files&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Select this option to remove all Help files in all installed languages. You should not remove Help files unless the client is also being removed.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Microsoft Dynamics AX Object Server (&lt;i&gt;instance name&lt;/i&gt;)&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Select this option to remove a specific Application Object Server (AOS) instance.  &lt;p&gt;Before you remove an AOS instance, use the Microsoft Dynamics AX Configuration utility to point all clients to a valid AOS instance, or update the shared configuration file.  &lt;p&gt;When you remove an AOS instance, it is not automatically removed from the list of batch and load balancing servers. After you uninstall an AOS instance, you must manually delete it by using the Server configuration form or the Cluster configuration form.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;ol start=&quot;3&quot;&gt; &lt;li&gt;A message box asks you to confirm that you want to uninstall. To proceed, click &lt;b&gt;Yes&lt;/b&gt;.&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;&lt;strong&gt;Remove remaining components manually&lt;/strong&gt;  &lt;p&gt;If you choose to remove an entire installation, some components remain after &lt;b&gt;Add or Remove Programs&lt;/b&gt; is finished. The following table provides more information about removing components manually.  &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;To remove this&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Do this&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Application files&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Delete the application file directory from the location that you installed it to.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Database and log files&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Use database server administration tools to delete the database and log files.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Role Centers and the Enterprise Portal framework&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Delete Web sites by using SharePoint Central Administration.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Reporting extensions&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;· Delete SQL Server Reporting Services objects, such as data sources, reports, and report models by using Reporting Services.  &lt;p&gt;· Delete the contents of the Microsoft Dynamics AX report folder.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Analysis extensions&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Delete SQL Server Analysis Services objects, such as databases, cubes, and models by using Analysis Services.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/6192773848233110823/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/uninstall-microsoft-dynamics-ax.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6192773848233110823'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6192773848233110823'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/uninstall-microsoft-dynamics-ax.html' title='Uninstall Microsoft Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-1359526697063459846</id><published>2014-09-19T00:22:00.001+03:00</published><updated>2014-09-19T00:22:42.410+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Development"/><category scheme="http://www.blogger.com/atom/ns#" term="X++"/><title type='text'>Create and Post inventory journal by code : Dynamics AX</title><content type='html'>&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; InventJournalTable&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTable; &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; InventJournalTrans&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; InventJournalNameId&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalName; &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; InventDim&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventDim; &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JournalCheckPost&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; journalCheckPost; &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/p&gt; &lt;p&gt;&lt;strong&gt;//Below code creates journal header&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTable.clear(); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalName =&amp;nbsp; InventJournalName::standardJournalName(InventJournalType::Movement); &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTable.initFromInventJournalName(InventJournalName::find(inventJournalName )); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTable.insert(); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/p&gt; &lt;p&gt;&lt;strong&gt;//Below code creates journal lines&lt;/strong&gt; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans.clear(); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans.initFromInventJournalTable(inventJournalTable); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans.TransDate = systemDateGet(); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans.ItemId = &quot;MDJ0001&quot;; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans.initFromInventTable(InventTable::find(&quot;MDJ0001&quot;)); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans.Qty = 2500; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventDim.InventSiteId&amp;nbsp; = &#39;12&#39;; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventDim.InventLocationId = &#39;1201&#39;; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventDim.wMSLocationId = &#39;BULK-001&#39;; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans.InventDimId = inventDim::findOrCreate(inventDim).inventDimId; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; inventJournalTrans.insert(); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/p&gt; &lt;p&gt;&lt;strong&gt;//The below code posts the journal &lt;br&gt;&lt;/strong&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; journalCheckPost = InventJournalCheckPost::newPostJournal(inventJournalTable); &lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; journalCheckPost.run();&lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/1359526697063459846/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/create-and-post-inventory-journal-by.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/1359526697063459846'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/1359526697063459846'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/create-and-post-inventory-journal-by.html' title='Create and Post inventory journal by code : Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-7567263683373922093</id><published>2014-09-15T15:17:00.001+03:00</published><updated>2014-09-15T15:17:45.876+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Workflow"/><title type='text'>Configure the workflow notification options [AX 2012]</title><content type='html'>&lt;p&gt;Notifications may be sent to you when workflow-related events occur. For example, a notification may be sent to you when a document is assigned to you for approval or when the workflow process is completed for a document that you submitted. You can specify how you want to receive workflow notifications. &lt;ol&gt; &lt;li&gt; &lt;p&gt;Click File &amp;gt; Tools &amp;gt; &lt;strong&gt;Options&lt;/strong&gt;.&lt;/p&gt; &lt;li&gt; &lt;p&gt;In the left pane of the &lt;strong&gt;Options&lt;/strong&gt; form, click &lt;strong&gt;Notifications&lt;/strong&gt;.&lt;/p&gt; &lt;li&gt; &lt;p&gt;In the &lt;strong&gt;Receive notifications every (minutes)&lt;/strong&gt; field, enter the number of minutes to specify how often you want to receive notifications.&lt;/p&gt; &lt;li&gt; &lt;p&gt;In the &lt;strong&gt;Line-item notification type&lt;/strong&gt; list, specify how you want to receive workflow notifications for line items from the following options: &lt;ul&gt; &lt;li&gt; &lt;p&gt;&lt;strong&gt;Grouped&lt;/strong&gt; – Notifications for line items are grouped into a single notification.&lt;/p&gt; &lt;li&gt; &lt;p&gt;&lt;strong&gt;Individual&lt;/strong&gt; – A notification is sent for each line item.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt; &lt;li&gt; &lt;p&gt;To receive notifications in the Microsoft Dynamics AX client, select the &lt;strong&gt;Show notifications in the Microsoft Dynamics AX client&lt;/strong&gt; check box. &lt;p&gt;If you select the &lt;strong&gt;Show notifications in the Microsoft Dynamics AX client&lt;/strong&gt; check box, you can also specify whether you want to receive notifications as pop-up messages. To receive pop-up messages, select the &lt;strong&gt;Show pop-ups for notifications&lt;/strong&gt; check box.&lt;/p&gt; &lt;li&gt; &lt;p&gt;To receive notifications as email, select the &lt;strong&gt;Send notifications in email&lt;/strong&gt; check box.&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/7567263683373922093/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/configure-workflow-notification-options.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/7567263683373922093'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/7567263683373922093'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/configure-workflow-notification-options.html' title='Configure the workflow notification options [AX 2012]'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-4490682023590538898</id><published>2014-09-14T15:24:00.001+03:00</published><updated>2014-09-14T15:24:02.421+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Reports"/><category scheme="http://www.blogger.com/atom/ns#" term="SSRS"/><title type='text'>Walkthrough: Creating a Report Bound to a Report Data Provider Class (X++ Business Logic) [AX 2012]</title><content type='html'>&lt;p&gt;In this walkthrough, you use a report data provider (RDP) class with business logic to process data and then display the outcome of the business logic on a report. &lt;/p&gt; &lt;p&gt;An RDP class is an X++ class that is used to access and process data for a Reporting Services report. The options for a data source type for a Microsoft Dynamics AX report are query, business logic, and RDP. An RDP class is an appropriate data source type when the following conditions are met. &lt;/p&gt; &lt;ol&gt; &lt;li&gt;You cannot query directly for the data you want to render on a report.  &lt;li&gt;The data to be processed and displayed is from Microsoft Dynamics AX. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;The following illustration is a preview of the report that you create in this walkthrough.  &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjng-h58s78CQwagV_XeEK2vtiWI4rvtqywrTHpG5M_ZTsbeD_DZviIVKb3W78QHaqdr3VUF32J8gdMpf3UG7vB6SE3qKf8H7hD90L8geTENCJ-X0GK-YcU6H2X3lM6cgji_RsfPMUj4Vga/s1600-h/clip_image00111.gif&quot;&gt;&lt;img title=&quot;clip_image001&quot; style=&quot;border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-top-width: 0px&quot; border=&quot;0&quot; alt=&quot;clip_image001&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8OZUu0FVj9MDbhVYHdaypuoEyHAbCUkEoyyMRcs0N0wzY2Y_k4aDVZsZwdG7w_8_osH11qOC7iKvITguknxT2U-g288Oo7mPnqYml8IPoYcaV7_mZYZsMc-egFujPyL3XeBmorAjwCzL1/?imgmax=800&quot; width=&quot;2&quot; height=&quot;2&quot;&gt;&lt;/a&gt;&lt;/b&gt;&lt;b&gt;Note&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The data that displays in your report may vary depending upon the sample data that is available to you.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt; &lt;p&gt;The following elements are required to set RDP as your data source type. &lt;/p&gt; &lt;ul&gt; &lt;li&gt;Temporary table – RDP class fills a temporary table with data that will be used by Reporting Services to display the report.  &lt;li&gt;Data contract class – defines the parameters in the report.  &lt;li&gt;Report data provider class – processes business logic based on parameters and a query, and then returns the tables as a dataset for the report. &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;&lt;strong&gt;&lt;font size=&quot;4&quot;&gt;This walkthrough illustrates the following tasks:&lt;/font&gt;&lt;/strong&gt; &lt;/p&gt; &lt;ul&gt; &lt;li&gt;Creating a temporary table  &lt;li&gt;Defining a report data provider class  &lt;li&gt;Defining the report parameters  &lt;li&gt;Defining a method to return data to Reporting Services  &lt;li&gt;Adding business logic for the report  &lt;li&gt;Creating a reporting project  &lt;li&gt;Binding a report to a report data provider class &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;&lt;br&gt;&lt;strong&gt;Creating a Temporary Table&lt;/strong&gt; &lt;/p&gt; &lt;p&gt;Data for an RDP report is preprocessed and then stored in a temporary table. The temporary table is used by Reporting Services when the report is displayed. A table returned by a method can be a temporary table (&lt;b&gt;InMemory&lt;/b&gt; or &lt;b&gt;TempDB&lt;/b&gt;) or a regular table. When the data returned is used for reporting only, it is a best practice to use a temporary table. &lt;/p&gt; &lt;ul&gt; &lt;li&gt;Use an InMemory temporary table if the dataset is small, for reports that will display fewer than 1000 records.  &lt;li&gt;Use a TempDB temporary table for large datasets to improve performance. &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;In this section you will create a temporary table to store the data for the report. &lt;/p&gt; &lt;p&gt;To create a temporary table &lt;/p&gt; &lt;ol&gt; &lt;li&gt;In the AOT, expand the &lt;b&gt;Data Dictionary&lt;/b&gt; node, right-click the &lt;b&gt;Tables&lt;/b&gt; node, and then click &lt;b&gt;New Table&lt;/b&gt;.  &lt;li&gt;Right-click the table, and click &lt;b&gt;Properties&lt;/b&gt;.  &lt;li&gt;In the Properties window, set the &lt;b&gt;Name&lt;/b&gt; property to &lt;b&gt;TmpCustTableSample&lt;/b&gt; and set the &lt;b&gt;Table Type&lt;/b&gt; property to &lt;b&gt;TempDB&lt;/b&gt;. This will define the table as a SQL Server temporary table.  &lt;li&gt;Expand the node next to the &lt;b&gt;TmpCustTableSample&lt;/b&gt; table so that you can see the &lt;b&gt;Fields&lt;/b&gt; node.  &lt;li&gt;Press Ctrl+D to open another AOT window and move the window so you can see both AOT windows.  &lt;li&gt;In the second AOT, expand the &lt;b&gt;Data Dictionary&lt;/b&gt; node, expand the &lt;b&gt;Extended Data Types&lt;/b&gt; node, and drag the following types to the &lt;b&gt;Field&lt;/b&gt; node in the first AOT window:  &lt;ul&gt; &lt;li&gt;AccountNum  &lt;li&gt;CustName  &lt;li&gt;LogisticsAddressing  &lt;li&gt;CustGroupId  &lt;li&gt;Phone  &lt;li&gt;CustInvoiceAccount  &lt;li&gt;ActionDays  &lt;li&gt;InclTax &lt;/li&gt;&lt;/ul&gt; &lt;li&gt;In the second AOT window, expand the &lt;b&gt;Base Enums&lt;/b&gt; node and drag the &lt;b&gt;CustAccountStatement&lt;/b&gt; enumeration to the &lt;b&gt;Fields&lt;/b&gt; node of the first AOT window. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;&lt;strong&gt;Defining a Report Data Provider Class&lt;/strong&gt; &lt;/p&gt; &lt;p&gt;The RDP class is a data provider that allows you to add business logic for the data that is displayed on a report. The business logic for this example prompts the end user for parameter values, processes business logic to generate data in a table, and then returns the table to render in the report. In this section, you define the RDP class by extending the SRSReportDataProviderBase class. Then add the TmpCustTableSample table as a global variable. The following list describes the attributes that are attached to the RDP class for this example: &lt;/p&gt; &lt;ul&gt; &lt;li&gt;Attach the SRSReportQueryAttribute attribute to specify the query to use to get the data for the report. &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;For this example, set the attribute to the Cust query. &lt;/p&gt; &lt;ul&gt; &lt;li&gt;Attach the SRSReportParameterAttribute attribute to specify the data contract class that defines the report parameters for the report. &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;For this example, set the attribute to the SrsRDPContractSampledata contract. &lt;/p&gt; &lt;p&gt;To define a report data provider class &lt;/p&gt; &lt;ol&gt; &lt;li&gt;In the AOT, right-click the &lt;b&gt;Classes&lt;/b&gt; node, and then click &lt;b&gt;New Class&lt;/b&gt;.  &lt;li&gt;Right-click the new class, click &lt;b&gt;Rename&lt;/b&gt;, and then enter &lt;b&gt;SrsRDPSampleClass&lt;/b&gt;.  &lt;li&gt;Expand &lt;b&gt;SrsRDPSampleClass&lt;/b&gt;, right-click &lt;b&gt;classDeclaration&lt;/b&gt;, and then click &lt;b&gt;View Code&lt;/b&gt;.  &lt;li&gt;In code editor, enter the following code in the class declaration to define the class. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;X++ &lt;/p&gt; &lt;p&gt;[ &lt;/p&gt; &lt;p&gt;SRSReportQueryAttribute (querystr(Cust)), &lt;/p&gt; &lt;p&gt;SRSReportParameterAttribute(classstr(SrsRDPContractSample)) &lt;/p&gt; &lt;p&gt;] &lt;/p&gt; &lt;p&gt;public class SrsRdpSampleClass extends SRSReportDataProviderBase &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;TmpCustTableSample tmpCust; &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Defining a Data Contract Class&lt;/strong&gt; &lt;/p&gt; &lt;p&gt;An RDP class must have a data contract if the report has one or more &lt;i&gt;report parameters&lt;/i&gt;. This example defines three report parameters for account number, account statement, and whether to include tax. When you print the report, you can specify which data to print based on the report parameters. For example, you can specify to only print transactions for account number 4000. &lt;/p&gt; &lt;p&gt;A data contract is an X++ class with getters, setters, and the DataMemberAttribute attribute. The data contract defines the parameters that the report uses. &lt;/p&gt; &lt;p&gt;To define a data contract class &lt;/p&gt; &lt;ol&gt; &lt;li&gt;In the AOT, right-click the &lt;b&gt;Classes&lt;/b&gt; node, and then select &lt;b&gt;New Class&lt;/b&gt;.  &lt;li&gt;Right-click the new class, click &lt;b&gt;Rename&lt;/b&gt;, and then enter &lt;b&gt;SrsRDPContractSample&lt;/b&gt;.  &lt;li&gt;Expand &lt;b&gt;SrsRDPContractSample&lt;/b&gt;, right-click &lt;b&gt;classDeclaration&lt;/b&gt;, and then click &lt;b&gt;View Code&lt;/b&gt;.  &lt;li&gt;In code editor, enter the following code in the class declaration to define the class. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;X++ &lt;/p&gt; &lt;p&gt;[DataContractAttribute] &lt;/p&gt; &lt;p&gt;public class SrsRDPContractSample &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;AccountNum accountNum; &lt;/p&gt; &lt;p&gt;CustAccountStatement accountStmt; &lt;/p&gt; &lt;p&gt;boolean inclTax; &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;A data contract class has methods with the DataMemberAttribute attribute. The name that follows this attribute is the parameter name that displays in Visual Studio when you bind a report data set to the RDP class. In this section, add a method for each of the report parameters and name them parmAccountNum, parmAccountStmt, and parmInclTax. &lt;/p&gt; &lt;p&gt;To define data contract methods &lt;/p&gt; &lt;ol&gt; &lt;li&gt;Right-click &lt;b&gt;SrsRDPContractSample&lt;/b&gt;, point to &lt;b&gt;New&lt;/b&gt;, and then click &lt;b&gt;Method&lt;/b&gt;.  &lt;li&gt;Edit the method so that it contains the following code. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;X++ &lt;/p&gt; &lt;p&gt;[DataMemberAttribute(&quot;AccountNum&quot;)] &lt;/p&gt; &lt;p&gt;public AccountNum parmAccountNum(AccountNum _accountNum = accountNum) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;accountNum = _accountNum; &lt;/p&gt; &lt;p&gt;return accountNum; &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;Right-click &lt;b&gt;SrsRDPContractSample&lt;/b&gt;, point to &lt;b&gt;New&lt;/b&gt;, and then click &lt;b&gt;Method&lt;/b&gt;.  &lt;li&gt;Edit the method so that it contains the following code. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;X++ &lt;/p&gt; &lt;p&gt;[DataMemberAttribute(&quot;CustAccountStatement&quot;)] &lt;/p&gt; &lt;p&gt;public CustAccountStatement parmAccountStmt(CustAccountStatement _accountStmt = accountStmt) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;accountStmt = _accountStmt; &lt;/p&gt; &lt;p&gt;return accountStmt; &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;Right-click &lt;b&gt;SrsRDPContractSample&lt;/b&gt;, point to &lt;b&gt;New&lt;/b&gt;, and then click &lt;b&gt;Method&lt;/b&gt;.  &lt;li&gt;Edit the method so that it contains the following code. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;X++ &lt;/p&gt; &lt;p&gt;[DataMemberAttribute(&quot;InclTax&quot;)] &lt;/p&gt; &lt;p&gt;public boolean parmInclTax(boolean _inclTax = inclTax) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;inclTax = _inclTax; &lt;/p&gt; &lt;p&gt;return inclTax; &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Defining a Method to Return Data to Reporting Services&lt;/strong&gt; &lt;/p&gt; &lt;p&gt;A method to return the processed data in the temporary table to Reporting Services is needed. In this section, add a method named &lt;b&gt;getTmpCustTable&lt;/b&gt; and attach the SRSReportDataSetAttribute attribute to indicate the dataset for the report. &lt;/p&gt; &lt;p&gt;To define a method to return the data to Reporting Services &lt;/p&gt; &lt;ol&gt; &lt;li&gt;Right-click &lt;b&gt;SrsRdpSampleClass&lt;/b&gt;, point to &lt;b&gt;New&lt;/b&gt;, and then click &lt;b&gt;Method&lt;/b&gt;.  &lt;li&gt;Edit the method so that it contains the following code. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;X++ &lt;/p&gt; &lt;p&gt;[SRSReportDataSetAttribute(&quot;TmpCust&quot;)] &lt;/p&gt; &lt;p&gt;public TmpCustTableSample getTmpCustTable() &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;select * from tmpCust; &lt;/p&gt; &lt;p&gt;return tmpCust; &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Adding Business Logic for the Report&lt;/strong&gt; &lt;/p&gt; &lt;p&gt;The business logic for this example prompts the end user for parameter values, processes business logic to generate data in a table, and then returns the table to render in the report. &lt;/p&gt; &lt;p&gt;The report business logic is provided in the processReport method. This method is called by Reporting Services at runtime. The following example illustrates how the processReport method computes data and populates the data table that is returned to Reporting Services. In this section, override the processReport method to provide business logic for your report. &lt;/p&gt; &lt;p&gt;To add business logic for the report &lt;/p&gt; &lt;ol&gt; &lt;li&gt;Right-click &lt;b&gt;SrsRdpSampleClass&lt;/b&gt;, point to &lt;b&gt;Override method&lt;/b&gt;, and then click &lt;b&gt;processReport&lt;/b&gt;.  &lt;li&gt;Edit the method so that it contains the following code. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;X++ &lt;/p&gt; &lt;p&gt;public void processReport() &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;AccountNum accountNumber; &lt;/p&gt; &lt;p&gt;CustAccountStatement custAcctStmt; &lt;/p&gt; &lt;p&gt;boolean boolInclTax; &lt;/p&gt; &lt;p&gt;Query query; &lt;/p&gt; &lt;p&gt;QueryRun queryRun; &lt;/p&gt; &lt;p&gt;QueryBuildDataSource queryBuildDataSource; &lt;/p&gt; &lt;p&gt;QueryBuildRange queryBuildRange; &lt;/p&gt; &lt;p&gt;CustTable queryCustTable; &lt;/p&gt; &lt;p&gt;SrsRdpContractSample dataContract; &lt;/p&gt; &lt;p&gt;// Get the query from the runtime using a dynamic query. &lt;/p&gt; &lt;p&gt;// This base class method reads the query specified in the SRSReportQueryAttribute attribute. &lt;/p&gt; &lt;p&gt;query = this.parmQuery(); &lt;/p&gt; &lt;p&gt;// Get the parameters passed from runtime. &lt;/p&gt; &lt;p&gt;// The base class methods read the SRSReportParameterAttribute attribute. &lt;/p&gt; &lt;p&gt;dataContract = this.parmDataContract(); &lt;/p&gt; &lt;p&gt;accountNumber = dataContract.parmAccountNum(); &lt;/p&gt; &lt;p&gt;custAcctStmt = dataContract.parmAccountStmt(); &lt;/p&gt; &lt;p&gt;boolInclTax = dataContract.parmInclTax(); &lt;/p&gt; &lt;p&gt;// Add parameters to the query. &lt;/p&gt; &lt;p&gt;queryBuildDataSource = query.dataSourceTable(tablenum(CustTable)); &lt;/p&gt; &lt;p&gt;if(accountNumber) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;queryBuildRange = queryBuildDataSource.findRange(fieldnum(CustTable, AccountNum)); &lt;/p&gt; &lt;p&gt;if (!queryBuildRange) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;queryBuildRange = queryBuildDataSource.addRange(fieldnum(CustTable, AccountNum)); &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;// If an account number has not been set, then use the parameter value to set it. &lt;/p&gt; &lt;p&gt;if(!queryBuildRange.value()) &lt;/p&gt; &lt;p&gt;queryBuildRange.value(accountNumber); &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;if(custAcctStmt) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;queryBuildRange = queryBuildDataSource.findRange(fieldnum(CustTable, AccountStatement)); &lt;/p&gt; &lt;p&gt;if (!queryBuildRange) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;queryBuildRange = queryBuildDataSource.addRange(fieldnum(CustTable, AccountStatement)); &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;// If an account statement has not been set, then use the parameter value to set it. &lt;/p&gt; &lt;p&gt;if(!queryBuildRange.value()) &lt;/p&gt; &lt;p&gt;queryBuildRange.value(int2str(custAcctStmt)); &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;if(boolInclTax) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;queryBuildRange = queryBuildDataSource.findRange(fieldnum(CustTable, InclTax)); &lt;/p&gt; &lt;p&gt;if (!queryBuildRange) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;queryBuildRange = queryBuildDataSource.addRange(fieldnum(CustTable, InclTax)); &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;// If flag to include tax has not been set, then use the parameter value to set it. &lt;/p&gt; &lt;p&gt;if(!queryBuildRange.value()) &lt;/p&gt; &lt;p&gt;queryBuildRange.value(int2str(boolInclTax)); &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;// Run the query with modified ranges. &lt;/p&gt; &lt;p&gt;queryRun = new QueryRun(query); &lt;/p&gt; &lt;p&gt;ttsbegin; &lt;/p&gt; &lt;p&gt;while(queryRun.next()) &lt;/p&gt; &lt;p&gt;{ &lt;/p&gt; &lt;p&gt;tmpCust.clear(); &lt;/p&gt; &lt;p&gt;queryCustTable = queryRun.get(tablenum(CustTable)); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.AccountNum = queryCustTable.AccountNum; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.CustName = queryCustTable.name(); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.LogisticsAddressing = queryCustTable.address(); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.CustGroupId = queryCustTable.CustGroup; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.Phone = queryCustTable.phone(); &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.CustInvoiceAccount = queryCustTable.InvoiceAccount; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.CustAccountStatement = queryCustTable.AccountStatement; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.InclTax = queryCustTable.InclTax; &lt;/p&gt; &lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; tmpCust.insert(); &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;ttscommit; &lt;/p&gt; &lt;p&gt;} &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Creating a Reporting Project&lt;/strong&gt; &lt;/p&gt; &lt;p&gt;Next, create a reporting project in Microsoft Visual Studio. When you create a reporting project, you use the Report Model to create a Reporting Services report. &lt;/p&gt; &lt;p&gt;To create a reporting project &lt;/p&gt; &lt;ol&gt; &lt;li&gt;Open Microsoft Visual Studio.  &lt;li&gt;On the &lt;b&gt;File&lt;/b&gt; menu, point to &lt;b&gt;New&lt;/b&gt;, and then click &lt;b&gt;Project&lt;/b&gt;. The &lt;b&gt;New Project&lt;/b&gt; dialog box displays.  &lt;li&gt;In the &lt;b&gt;Installed Templates&lt;/b&gt; pane, click &lt;b&gt;Microsoft Dynamics AX&lt;/b&gt;. In the &lt;b&gt;Templates&lt;/b&gt; pane, click &lt;b&gt;Report Model&lt;/b&gt;.  &lt;li&gt;In the &lt;b&gt;Name&lt;/b&gt; box, type &lt;b&gt;SampleRDPReport&lt;/b&gt;, and in the &lt;b&gt;Location&lt;/b&gt; box, type a location.  &lt;li&gt;Click &lt;b&gt;OK&lt;/b&gt;. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;A reporting project contains a report model where you can add a report to the model. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;Binding a Report to a Report Data Provider Class&lt;/strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt; &lt;p&gt;Now that you have created a reporting project, you are ready to define an auto design report that displays data from the Cust query. The following procedure explains how to create an auto design report that uses the RDP class as the data source. &lt;/p&gt; &lt;p&gt;To create an auto design report &lt;/p&gt; &lt;ol&gt; &lt;li&gt;In Solution Explorer, right-click the &lt;b&gt;ReportModel&lt;/b&gt; node, point to &lt;b&gt;Add&lt;/b&gt; and then click &lt;b&gt;Report&lt;/b&gt;.  &lt;li&gt;In Model Editor, right-click the &lt;b&gt;Report1&lt;/b&gt; node, and then click &lt;b&gt;Rename&lt;/b&gt;.  &lt;li&gt;Type &lt;b&gt;CustomerReport&lt;/b&gt; as the name.  &lt;li&gt;Right-click the &lt;b&gt;Datasets&lt;/b&gt; node, and then click &lt;b&gt;Add Dataset&lt;/b&gt;.  &lt;li&gt;In the &lt;b&gt;Properties&lt;/b&gt; window, specify the following values. &lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Property&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Value&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Data Source&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Dynamics AX&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Data Source Type&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Report Data Provider&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Default Layout&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Table&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Dynamic Filters&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;True&lt;/b&gt;  &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhzDgKjbAJ6Fh2ta-kDOGcd2_dGV3wR186-r-WTh_fFS8l7R2ilRbZyWk2PICCOhxbA5WJqAUEWdLa175sPJ1SNfqnXPZgxOqqPCEAhBeO6za2yn47nFmv_qQ4N30HW8QBQnLMenyFhw1CI/s1600-h/clip_image00112.gif&quot;&gt;&lt;img title=&quot;clip_image001[1]&quot; style=&quot;border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-top-width: 0px&quot; border=&quot;0&quot; alt=&quot;clip_image001[1]&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEheklPMO8JrqeSfpJukDMz24itl_roRvmiBExDg1Hq7gNriqjsBkMgd4X8_oC03drDUc-skbK3zdOpO2QdkB2zSZwb8KdEVFKUw70vncUqaPfa0lH5k17nPBSVLey3xQEbpX8UFBDWTuupx/?imgmax=800&quot; width=&quot;2&quot; height=&quot;2&quot;&gt;&lt;/a&gt;&lt;/b&gt;&lt;b&gt;Note&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;This setting is for dynamic parameters on the report. Setting the property to &lt;b&gt;True&lt;/b&gt; allows you to filter the report by setting a range on any fields from the data source table.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Name&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Customer&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Query&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Click the ellipsis button (…). A dialog box displays where you can select an RDP class that is defined in the AOT and identify the fields that you want to use. Select the &lt;b&gt;SrsRDPSampleClass&lt;/b&gt; class and click &lt;b&gt;Next&lt;/b&gt;. In the &lt;b&gt;Select Fields&lt;/b&gt; dialog box, keep all the checkboxes selected, and click &lt;b&gt;OK&lt;/b&gt;.  &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSxzO7VZRDkvpuubGNtjrcl_Feht5aqvuJ8MXg67vlvHjzAUrlR6HisyOtEEs4lmzutsUiMbPsG46k5WaTFCWouYoZt9eYAmTZw403Jbm-XGr15mRPw8WUBz-RyLokZEu08DXIJ-rSSAdi/s1600-h/clip_image00122.gif&quot;&gt;&lt;img title=&quot;clip_image001[2]&quot; style=&quot;border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-top-width: 0px&quot; border=&quot;0&quot; alt=&quot;clip_image001[2]&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjCNudCUqLPzWfzXd5G5cIuvj9-uUW1nO-G4TpL86gkqtbIqhhcvjW7dh2EkNSOJFmJpzvTtKufuctXie0B8AQyV7bRaX9rxfPbRReX9fqVRFR_U3O1ZQo7aJE8pBNssEDaZ8-ocSe3IPpn/?imgmax=800&quot; width=&quot;2&quot; height=&quot;2&quot;&gt;&lt;/a&gt;&lt;/b&gt;&lt;b&gt;Note&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Based on what you select, the Query property value is updated. In this case, the query is &lt;b&gt;SELECT * FROM SrsRDPSampleClass.TmpCust&lt;/b&gt;.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;In Model Editor, select the &lt;b&gt;Customer&lt;/b&gt; node and drag it onto the &lt;b&gt;Designs&lt;/b&gt; node. An auto design named &lt;b&gt;AutoDesign1&lt;/b&gt; is created for the report. &lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEheG-In_ccLjgb5i4bKnz_HGaIMiaSWXibA9ZYhuyuHnZhhT3vBAZYze0cTZtSeM9VToe-tcrRGGb62BcguqAuhyphenhyphenpAsmZN8shyphenhyphen5hW8UPJxEXmZdukJTNipDWoOeST_iZ-XRFE7B0Bs7iUgT/s1600-h/clip_image00132.gif&quot;&gt;&lt;img title=&quot;clip_image001[3]&quot; style=&quot;border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-top-width: 0px&quot; border=&quot;0&quot; alt=&quot;clip_image001[3]&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhV75hvikkYOHuM4cKd0ZWjR6O7moYXjpxrNcqxExdgUc2VOwuz2I3QccIA4l601VUfpH74NsurT3ss2NhiHOJsp73HYS9PXpHia9fQDQotgr2Ryi9hsRm3ovUVU7DYxQgWOu_3Ttu6DxoC/?imgmax=800&quot; width=&quot;2&quot; height=&quot;2&quot;&gt;&lt;/a&gt;&lt;/b&gt;&lt;b&gt;Note&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;If you expand the &lt;b&gt;Parameters&lt;/b&gt; node you see the parameters that you defined in the data contract class. When you define nested data contract parameters, they are listed under the &lt;b&gt;Parameters&lt;/b&gt; node also. &lt;/p&gt; &lt;p&gt;Select the &lt;b&gt;SrsRDPSampleClass_DynamicParameter&lt;/b&gt; parameter. In the &lt;b&gt;Properties&lt;/b&gt; window, the &lt;b&gt;AOT Query&lt;/b&gt; property is set to the query specified in the parmQuery method in the RDP class.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;Select &lt;b&gt;AutoDesign1&lt;/b&gt; and then click the &lt;b&gt;Preview&lt;/b&gt; button.  &lt;li&gt;Enter a value for &lt;b&gt;Account number&lt;/b&gt; and &lt;b&gt;Account statement&lt;/b&gt; that returns data and then click the &lt;b&gt;Report&lt;/b&gt; tab to preview the report. &lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiFJSyQ8aGvylRnMrfxkd7IBRBBglR4C6qbkq8ebVmxfTNgOaCAmF9S5QgOtoNOyuCJMdZDebsHw_f5VY0Vrt66xVBEhxeC9LGGbHtXqxZmlryik1BQbxBPZbwpgnmr4XuGYlaTjB7vOBrQ/s1600-h/clip_image00142.gif&quot;&gt;&lt;img title=&quot;clip_image001[4]&quot; style=&quot;border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-top-width: 0px&quot; border=&quot;0&quot; alt=&quot;clip_image001[4]&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYmNhnUmecHvluYz-stv-lBXl8lunbmqPwMpL-7ESez9IO3pPgKLM3rERm7leBDgbjGpF2LPin8FcBWH7mozSSAK_flfBGbqUWAYUTzvr6e_vg_jz-WGg3m-d64ZedLZNRtAzqw0Nq-jnB/?imgmax=800&quot; width=&quot;2&quot; height=&quot;2&quot;&gt;&lt;/a&gt;&lt;/b&gt;&lt;b&gt;Note&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;You can use * to display all of the account numbers on the report. &lt;b&gt;Account statement&lt;/b&gt; is an enumeration and there is no wild card value for enumerations. Check your sample data to determine a valid enumeration value for &lt;b&gt;Account statement&lt;/b&gt;. &lt;/p&gt; &lt;p&gt;The Select button displays because you set the &lt;b&gt;Dynamic Filters&lt;/b&gt; property to &lt;b&gt;True&lt;/b&gt; on the dataset. You have the option to click the &lt;b&gt;Select&lt;/b&gt; button to specify a range to filter the report and limit the data that displays on the report.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;p&gt;The next steps are to add layout and style templates, deploy, and add the report to a menu item so you can see it in Microsoft Dynamics AX. &lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/4490682023590538898/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/walkthrough-creating-report-bound-to.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/4490682023590538898'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/4490682023590538898'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/walkthrough-creating-report-bound-to.html' title='Walkthrough: Creating a Report Bound to a Report Data Provider Class (X++ Business Logic) [AX 2012]'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8OZUu0FVj9MDbhVYHdaypuoEyHAbCUkEoyyMRcs0N0wzY2Y_k4aDVZsZwdG7w_8_osH11qOC7iKvITguknxT2U-g288Oo7mPnqYml8IPoYcaV7_mZYZsMc-egFujPyL3XeBmorAjwCzL1/s72-c?imgmax=800" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-1797081540994180981</id><published>2014-09-10T20:07:00.001+03:00</published><updated>2014-09-10T20:07:22.767+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Dynamics AX"/><category scheme="http://www.blogger.com/atom/ns#" term="Inventory"/><title type='text'>Description of the main processing steps that are performed by the Inventory Close and the Inventory Recalculation in Dynamics AX</title><content type='html'>&lt;p&gt;When you run the Inventory Close routine or the Inventory Recalculation routine in Microsoft Dynamics AX, Microsoft Dynamics AX performs a sequence of steps in their processing. &lt;/p&gt; &lt;h5&gt;Steps that are performed by the Inventory Close routine&lt;/h5&gt;When you run the Close routine, Microsoft Dynamics AX performs the following steps:  &lt;ol&gt; &lt;li&gt;Check whether any Recalculations were run after the date that you choose for your Close. Microsoft Dynamics AX will cancel any of those later Recalculations before the Close can start.  &lt;li&gt;Put all the items that are to be processed into a queue. These items are stored in the InventCostList table. &lt;br&gt;&lt;b&gt;Note&lt;/b&gt; While a Close or Recalculation is processing, you can click &lt;strong&gt;Calculation/Calculation List&lt;/strong&gt; from the &lt;strong&gt;Close &amp;amp; adjustment&lt;/strong&gt; form to view the data in the InventCostList table. This shows which items are still to be processed by the Close or Recalculation process.  &lt;li&gt;Process each item from that queue sequentially. Microsoft Dynamics AX performs the following for each item:  &lt;ol&gt; &lt;li&gt;Settle individual receipts and issues against one another for the item according to the Inventory Model Group such as FIFO, Weighted Average.  &lt;ul&gt; &lt;li&gt;Make any required cost adjustments to the issue that was settled based on the cost of the receipt(s) against which the issue was settled.  &lt;li&gt;Update the inventory transactions to show the settlement and cost adjustment data.  &lt;li&gt;Write the settlement data into the Inventory Settlement table. The data will include records that show explicitly which Receipt(s) were settled to each Issue in addition to any cost adjustment that is made to the Issue that is settled. &lt;/li&gt;&lt;/ul&gt; &lt;li&gt;As soon as all possible transactions are processed for that item, Microsoft Dynamics AX looks for any transactions that are fully settled, and then update those transactions to &quot;Closed.&quot; For more information, see the &quot;What fields show that an inventory transaction is closed&quot; section. &lt;/li&gt;&lt;/ol&gt; &lt;li&gt;As soon as all the items are processed, the settlement records that were created are read and sorted by General Ledger Account. Then, Microsoft Dynamics AX summarizes all the cost adjustments that were made, and a General Ledger Journal is created and posted.  &lt;li&gt;If you select the &lt;strong&gt;Run recalculation after closing&lt;/strong&gt; check box in the &lt;strong&gt;Close&lt;/strong&gt; dialog box, a Recalculation will be run for all items up to today&#39;s date. &lt;/li&gt;&lt;/ol&gt; &lt;h5&gt;Steps that are performed by the Inventory Recalculation routine&lt;/h5&gt;The Inventory Recalculation routine does a similar job to the Inventory Close routine. However, there are a few differences. When you run the Recalculation routine, Microsoft Dynamics AX performs the following steps:  &lt;ol&gt; &lt;li&gt;Check whether any Recalculations were run after the date that you choose to run your Recalculation up to. Microsoft Dynamics AX will cancel any of those later Recalculations found before your Recalculation routine can start. &lt;br&gt;&lt;b&gt;Notes&lt;/b&gt;  &lt;ul&gt; &lt;li&gt;In the &lt;strong&gt;Select&lt;/strong&gt; dialog box, you can select item(s) for which you want to run the Recalculation, unlike the Close routine that always processes all items.  &lt;li&gt;While a Recalculation or Close is processing, you can click &lt;strong&gt;Calculation/Calculation List&lt;/strong&gt; from the &lt;strong&gt;Close &amp;amp; adjustment&lt;/strong&gt; form to view the data in the InventCostList table. This shows which items are still to be processed by that Close or Recalculation. &lt;/li&gt;&lt;/ul&gt; &lt;li&gt;Put all the items that are to be processed into a queue, and then store the queue in the InventCostList table.  &lt;li&gt;Process each item from that queue sequentially. Microsoft Dynamics AX performs the following for each item:  &lt;ul&gt; &lt;li&gt;Make a &quot;virtual&quot; settlement between individual receipts and issues for the item according to the Inventory Model Group such as FIFO, Weighted Average. This is a &quot;virtual&quot; settlement because it is occurs in the Recalculation’s calculations. However, the detailed settlement data that shows the explicit matching of each issue to the various receipts is not stored in the InventSettlement table. The only data that is stored is the cost adjustment that is made to the issue.  &lt;ul&gt; &lt;li&gt;Make any required cost adjustments to the issue that was settled based on the cost of the receipt(s) against which the issue was settled.  &lt;li&gt;Write a single settlement record for any cost adjustment that is made for that Issue into the Inventory Settlement table. &lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;/ul&gt; &lt;li&gt;As soon as all the items are processed, the cost adjustment settlement records that were created are read, sorted by General Ledger Account, and summarized and posted in a General Ledger Journal. &lt;/li&gt;&lt;/ol&gt; &lt;h5&gt;What fields show that an inventory transaction is closed&lt;/h5&gt;To show that an inventory transaction is &quot;closed&quot;, Microsoft Dynamics AX performs the following:  &lt;ol&gt; &lt;li&gt;When the Inventory Close routine has fully settled the Quantity and Financial Cost of a specific inventory transaction, Microsoft Dynamics AX updates the individual inventory transaction to show that the transaction is &quot;closed.&quot;  &lt;li&gt;For a transaction to be closed, it must meet the following criteria:  &lt;ul&gt; &lt;li&gt;The &quot;Quantity&quot; must match the &quot;Quantity Settled.&quot;  &lt;li&gt;The sum of &quot;Cost Amount Posted&quot; plus &quot;Cost Amount Adjustment&quot; must match the &quot;Cost Amount Settled.&quot; &lt;/li&gt;&lt;/ul&gt; &lt;li&gt;When those conditions are met, then the Close program will do the following:  &lt;ul&gt; &lt;li&gt;Set the field &quot;Value Open&quot; from &quot;Yes&quot; to &quot;No.&quot;  &lt;li&gt;Store the date of the close in the field &quot;Date Closed.&quot; &lt;/li&gt;&lt;/ul&gt;This means that the individual inventory transaction is &quot;closed.&quot; &lt;/li&gt;&lt;/ol&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/1797081540994180981/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/description-of-main-processing-steps.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/1797081540994180981'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/1797081540994180981'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/description-of-main-processing-steps.html' title='Description of the main processing steps that are performed by the Inventory Close and the Inventory Recalculation in Dynamics AX'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-2737901180528144899</id><published>2014-09-03T16:25:00.001+03:00</published><updated>2014-09-03T16:25:50.509+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Workflow"/><title type='text'>How to: Create a Workflow Task AX 2012</title><content type='html'>&lt;p&gt;A Microsoft Dynamics AX workflow task is a single unit of work that must be performed. A workflow may contain one or more tasks. &lt;/p&gt; &lt;p&gt;The following procedure describes how to create a new workflow task in the AOT. &lt;/p&gt; &lt;p&gt;&lt;strong&gt;To create a workflow task&lt;/strong&gt; &lt;/p&gt; &lt;ol&gt; &lt;li&gt;In the &lt;b&gt;AOT&lt;/b&gt;, expand the &lt;b&gt;Workflow&lt;/b&gt; node.  &lt;li&gt;Right-click the &lt;b&gt;Tasks&lt;/b&gt; node, and then click &lt;b&gt;Add-Ins&lt;/b&gt; &amp;gt; &lt;b&gt;Task wizard&lt;/b&gt;. The &lt;b&gt;Workflow wizard&lt;/b&gt; is displayed. This wizard will help you create a new workflow task.  &lt;li&gt;Click &lt;b&gt;Next&lt;/b&gt;.  &lt;li&gt;Set the following values for the wizard. &lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Value&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Description&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Name&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The name that will be used for the workflow task.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Workflow document&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The class that defines the workflow document for which you are creating a task. &lt;/p&gt; &lt;p&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjHXrnKPIcWTREHFnmfThm49b0DgtYFY89mDMTj3_Phya4CgUN9alujJ6HM5WUp7uGDOup6q9rE616fahpO7QOwrKYltlcSi0Bp6uQ6hLdJXSkg4-4LmNGnd42qN1IgSY22hyGEUs5h2HwM/s1600-h/clip_image001%25255B5%25255D.gif&quot;&gt;&lt;img title=&quot;clip_image001&quot; style=&quot;border-left-width: 0px; border-right-width: 0px; background-image: none; border-bottom-width: 0px; padding-top: 0px; padding-left: 0px; margin: 0px; display: inline; padding-right: 0px; border-top-width: 0px&quot; border=&quot;0&quot; alt=&quot;clip_image001&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg_PdteUcl-E-LqzoTlQpGr8tVnKvNUmDN1bM5OY4vqxPhDgYPX1R8wDtJmKMvslC1wihF9h-4mRX2gLvjifADOBGHOTBJbI9oWdSX3Zh-Emr82XqMPliuDOFtLmZNFPvdEz4f-UqXR3FcM/?imgmax=800&quot; width=&quot;2&quot; height=&quot;2&quot;&gt;&lt;/a&gt;&lt;b&gt;Note&lt;/b&gt; &lt;/p&gt; &lt;p&gt;This setting must match the &lt;b&gt;Document&lt;/b&gt; property setting used in the workflow type for the task.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Document preview field group&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The initial set of fields displayed in the unified work list. Select a field group from the root table specified in the &lt;b&gt;Workflow document&lt;/b&gt; that you selected. The &lt;b&gt;Workflow document &lt;/b&gt;value must be set before you can select a field group.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Document menu item&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Choose the menu item that points to the main form that displays the document for which you are creating a workflow task.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Document web menu item&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Choose the web menu item that points to the Enterprise Portal page that displays the document for which you are creating a workflow task.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;Specify which types of menu items you want to create. You can create menu items for the Microsoft Dynamics AX client, web menu items for Enterprise Portal, or items for both.  &lt;li&gt;Click &lt;b&gt;Next&lt;/b&gt;.  &lt;li&gt;Define the task outcomes. For each outcome that you want to support, supply a &lt;b&gt;Name&lt;/b&gt; for the outcome. The name cannot contain spaces. Specify the &lt;b&gt;Type&lt;/b&gt; for the outcome. Choose one of the following types:  &lt;ul&gt; &lt;li&gt;&lt;b&gt;Complete&lt;/b&gt; - Completes the workflow task and continues the workflow forward.  &lt;li&gt;&lt;b&gt;Return&lt;/b&gt; - Returns the task to the originator for changes and then resubmission back to workflow.  &lt;li&gt;&lt;b&gt;RequestChange&lt;/b&gt; - Sends the task to a specified user for changes and then resubmission back to workflow.  &lt;li&gt;&lt;b&gt;Deny&lt;/b&gt; - Completes the task as denied and continues the workflow forward. &lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;Click &lt;b&gt;Add&lt;/b&gt;.  &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; width=&quot;637&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot; width=&quot;635&quot;&gt; &lt;p&gt;&lt;b&gt;Note&lt;/b&gt;&lt;/p&gt; &lt;p&gt;Each task must have one outcome of type &lt;b&gt;Complete&lt;/b&gt;.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;After you have finished defining the outcomes, click &lt;b&gt;Next&lt;/b&gt;. A list of all of the resources that will be created for the workflow task is displayed.  &lt;li&gt;Click &lt;b&gt;Finish&lt;/b&gt; to create the resources. The wizard will create classes, menu items, web menu items, the task, and a project that contains all of the items.  &lt;li&gt;A dialog box will be displayed that indicates the status. Click &lt;b&gt;OK&lt;/b&gt;. The project that contains the workflow type resources is displayed. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;After a workflow task is created, you can add the workflow task to the &lt;b&gt;Supported Elements&lt;/b&gt; node of a workflow type. &lt;/p&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/2737901180528144899/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/how-to-create-workflow-task-ax-2012.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/2737901180528144899'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/2737901180528144899'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/how-to-create-workflow-task-ax-2012.html' title='How to: Create a Workflow Task AX 2012'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg_PdteUcl-E-LqzoTlQpGr8tVnKvNUmDN1bM5OY4vqxPhDgYPX1R8wDtJmKMvslC1wihF9h-4mRX2gLvjifADOBGHOTBJbI9oWdSX3Zh-Emr82XqMPliuDOFtLmZNFPvdEz4f-UqXR3FcM/s72-c?imgmax=800" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-8856372610730181589</id><published>2014-09-01T16:57:00.001+03:00</published><updated>2014-09-01T16:57:33.269+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Workflow"/><title type='text'>How to: Create a Workflow Document Class [AX 2012]</title><content type='html'>&lt;p&gt;Microsoft Dynamics AX table fields are defined in a query to create workflow conditions. A limitation of a Microsoft Dynamics AX query is that you cannot define calculated fields in the query itself. It is a common scenario to use calculated fields to determine the behavior of a workflow. For example, a dynamic sales total of all records in a table can be used as a workflow condition to determine whether the step should be used. To overcome this query limitation, you must use a workflow document class.  &lt;p&gt;The workflow document class that you create defines table fields for conditions in two ways: the Application Object Tree (AOT) query and parameter methods. The getQueryName method of the &lt;a href=&quot;http://msdn.microsoft.com/en-us/library/workflowdocument.aspx&quot;&gt;WorkflowDocument Class&lt;/a&gt; must be overridden to return the name of the query. You can optionally add calculated fields by adding parameter methods with a specific signature on the class.  &lt;p&gt;Before you begin these procedures, you must create a query that specifies the data that will be accessed.  &lt;p&gt;The following procedures show how to create a workflow document class including a parameter method for a calculated field.  &lt;p&gt;&lt;img title=&quot;Note&quot; alt=&quot;Note&quot; src=&quot;http://i.msdn.microsoft.com/areas/global/content/clear.gif&quot;&gt;&lt;strong&gt;Note&lt;/strong&gt;  &lt;p&gt;If you used the Workflow Wizard to create the workflow type, the workflow document class will have already been created by the wizard.  &lt;h5&gt;To create a workflow document class&lt;/h5&gt; &lt;ol&gt; &lt;li&gt; &lt;p&gt;In the AOT, expand the Classes node.&lt;/p&gt; &lt;li&gt; &lt;p&gt;Right-click the Classes node, and then select New Class. A class group displays under the Classes node.&lt;/p&gt; &lt;li&gt; &lt;p&gt;Right-click the new class, click Rename, and then enter a name for the workflow document class.&lt;/p&gt; &lt;li&gt; &lt;p&gt;Expand the new class, select classDeclaration, right-click the class declaration, and then click Edit.&lt;/p&gt; &lt;li&gt; &lt;p&gt;Enter the following code in the class declaration.  &lt;p&gt;&lt;a&gt;X++&lt;/a&gt;&lt;/p&gt;&lt;pre&gt;class &amp;lt;MyWorkflowDocumentClassName&amp;gt; extends WorkflowDocument&lt;br /&gt;{&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;Close the Editor window and click Yes to save changes.&lt;/p&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;Right-click the new class, point to Override Method, and then click getQueryName. A method node named getQueryName displays under the workflow document class node and the Editor window opens. &lt;br /&gt;&lt;p&gt;&lt;img title=&quot;Note&quot; alt=&quot;Note&quot; src=&quot;http://i.msdn.microsoft.com/areas/global/content/clear.gif&quot;&gt;&lt;strong&gt;Note&lt;/strong&gt; &lt;br /&gt;&lt;p&gt;Be sure to select getQueryName as the method to override. The WorkflowDocument.getQuery Method is used only internally to retrieve the actual query based on the string returned by theWorkflowDocument.getQueryName Method.&lt;/p&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;In the Editor window, enter the following code for the query method. &lt;br /&gt;&lt;p&gt;&lt;a&gt;X++&lt;/a&gt;&lt;/p&gt;&lt;pre&gt;QueryName getQueryName()&lt;br /&gt;{&lt;br /&gt;    return querystr(&amp;lt;MyWorkflowDocumentQueryName&amp;gt;);&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;p&gt;After you create the workflow document class, you can bind it to the workflow type. For more information, see How to: Associate a Workflow Document Class with a Workflow Type. &lt;br /&gt;&lt;p&gt;To add a calculated field to the workflow document class, it must: &lt;br /&gt;&lt;ul&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;Be named parm &amp;lt;name&amp;gt;.&lt;/p&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;Define the parameters CompanyId, TableId, and RecId.&lt;/p&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;Return an extended data type that will be included in the list of fields for defining conditions or notification messages. The label for the EDT must uniquely identify the value.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;h5&gt;To add a calculated field to the workflow document class&lt;/h5&gt;&lt;br /&gt;&lt;ol&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;In the workflow document class that you want to add a calculated field to, right-click the class, and then click New Method. A new method node displays under the Classes node.&lt;/p&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;Right-click the new method node, and then click Edit. Enter code that uses the format shown in the following code example.&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;p&gt;The following code example shows how to add a calculated field to determine the total credit amount for a journal. &lt;br /&gt;&lt;p&gt;&lt;a&gt;X++&lt;/a&gt;&lt;/p&gt;&lt;pre&gt;public TotalJournalCreditAmount parmTotalJournalCreditAmount(CompanyId _companyId, TableId _tableId, RecId _recId)&lt;br /&gt;{&lt;br /&gt;    // The calculateAmounts method contains business and validation logic   &lt;br /&gt;    this.calculateAmounts(_companyId, _tableId, _recId);&lt;br /&gt;&lt;br /&gt;    return totalJournalCreditAmount;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/8856372610730181589/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/how-to-create-workflow-document-class.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/8856372610730181589'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/8856372610730181589'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/09/how-to-create-workflow-document-class.html' title='How to: Create a Workflow Document Class [AX 2012]'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-6660865235395432362</id><published>2014-07-23T14:51:00.001+03:00</published><updated>2014-07-23T14:51:14.843+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Development"/><category scheme="http://www.blogger.com/atom/ns#" term="Workflow"/><title type='text'>How to: Create a Workflow Category [AX 2012]</title><content type='html'>&lt;p&gt;When you create a workflow type in Microsoft Dynamics AX, it must be assigned to a workflow category. The workflow category determines whether a workflow type is available in a specific module. If an appropriate workflow category does not already exist, you must create one. &lt;p&gt;For example, a workflow type for a customer invoice should not be available in the &lt;b&gt;Master planning&lt;/b&gt; module. To make the workflow type available only in the &lt;b&gt;Customer&lt;/b&gt; module, create a workflow category with the &lt;b&gt;Customer&lt;/b&gt; module selected. &lt;p&gt;The following procedure describes how to create a new workflow category. &lt;p&gt;To create a workflow category &lt;ol&gt; &lt;li&gt;In the &lt;b&gt;AOT&lt;/b&gt;, expand the &lt;b&gt;Workflow&lt;/b&gt; node. &lt;li&gt;Right-click the &lt;b&gt;Workflow Categories&lt;/b&gt; node, and then click &lt;b&gt;New Workflow Category&lt;/b&gt;. A new workflow category group displays under the &lt;b&gt;Workflow Categories&lt;/b&gt; node. &lt;li&gt;Right-click the new workflow category and then click &lt;b&gt;Properties&lt;/b&gt;. &lt;li&gt;In the &lt;b&gt;Properties&lt;/b&gt; sheet, set the following properties as required.&lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Property&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Value&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Name&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The name that is used to reference the workflow category.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Label&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The label used for the workflow category in the user interface.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Help Text&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The description of the workflow category displayed in the configuration user interface.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Module&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;The module that the workflow will be available in. The default is &lt;b&gt;Ledger&lt;/b&gt;.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;p&gt;After a workflow category is created, you can bind the workflow type to the new category. Typically, this is performed by the Workflow Wizard. The following procedure describes how to manually bind a workflow type to a workflow category. &lt;p&gt;To bind a workflow type to a workflow category &lt;ol&gt; &lt;li&gt;In the &lt;b&gt;AOT&lt;/b&gt;, expand the &lt;b&gt;Workflow&lt;/b&gt; node, and then expand the &lt;b&gt;Workflow Types&lt;/b&gt; node. &lt;li&gt;Right-click the workflow type that you want to bind a workflow category to, and then select &lt;b&gt;Properties&lt;/b&gt;. &lt;li&gt;In the &lt;b&gt;Properties&lt;/b&gt; sheet, set the &lt;b&gt;Category&lt;/b&gt; property to the workflow category created in the previous procedure.&lt;/li&gt;&lt;/ol&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/6660865235395432362/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/07/how-to-create-workflow-category-ax-2012.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6660865235395432362'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/6660865235395432362'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/07/how-to-create-workflow-category-ax-2012.html' title='How to: Create a Workflow Category [AX 2012]'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-5939276685102009247</id><published>2014-07-20T17:27:00.001+03:00</published><updated>2014-07-20T17:27:57.558+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Development"/><category scheme="http://www.blogger.com/atom/ns#" term="Workflow"/><title type='text'>How to: Create a New Module with Workflow [AX 2012]</title><content type='html'>&lt;p&gt;In Microsoft Dynamics AX, modules are enabled for workflow. However, in some cases, you will need to create a new module that contains workflow. In each module that contains workflow, a &lt;b&gt;Workflows&lt;/b&gt; list menu item must be added to the &lt;b&gt;Setup&lt;/b&gt; pane. The following procedures are described in this topic:&lt;/p&gt; &lt;ul&gt; &lt;li&gt;Creating a new module enumeration.  &lt;li&gt;Creating a display menu item for the &lt;b&gt;Workflows&lt;/b&gt; list.  &lt;li&gt;Creating a menu for the new module.  &lt;li&gt;How to display the new menu in the client. &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;&lt;strong&gt;To Add a Module to the ModuleAxapta Base Enum&lt;/strong&gt;&lt;/p&gt; &lt;ol&gt; &lt;li&gt;In the Application Object Tree (AOT), expand the &lt;b&gt;Data Dictionary&lt;/b&gt; node, expand &lt;b&gt;Base Enums&lt;/b&gt;, right-click &lt;b&gt;ModuleAxapta&lt;/b&gt;, and then click &lt;b&gt;New Element&lt;/b&gt;. A new enumeration displays under the &lt;b&gt;ModuleAxapta&lt;/b&gt;node.  &lt;li&gt;Right-click the new enumeration, and then click &lt;b&gt;Properties&lt;/b&gt;.  &lt;li&gt;In the &lt;b&gt;Properties&lt;/b&gt; sheet, select the &lt;b&gt;Label&lt;/b&gt; property, and then enter the label of the new module. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;&lt;strong&gt;To Create a Display Menu Item for the Workflows List&lt;/strong&gt;&lt;/p&gt; &lt;ol&gt; &lt;li&gt;In the AOT, expand the &lt;b&gt;Menu Items&lt;/b&gt; node.  &lt;li&gt;Right-click the &lt;b&gt;Display&lt;/b&gt; node, and then click &lt;b&gt;New Menu Item&lt;/b&gt;. A new menu item displays under the &lt;b&gt;Display&lt;/b&gt; node.  &lt;li&gt;Right-click the new display menu item, and then click &lt;b&gt;Properties&lt;/b&gt;.  &lt;li&gt;In the &lt;b&gt;Properties&lt;/b&gt; sheet, set the following properties. &lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Property&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Value&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Name&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to WorkflowConfigurations&amp;lt;xxx&amp;gt; where &amp;lt;xxx&amp;gt; is replaced by a reference to the name of the new module. For example, you could set this value to WorkflowConfigurationsRecruit for a new module named Recruiting.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Label&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set text or a label that represents the text for the workflows list in the client.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;ObjectType&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to Form.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Object&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to WorkflowTableListPage.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;EnumTypeParameter&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to ModuleAxapta.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;EnumParameter&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to the enum created in the preceding procedure.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;In the AOT, right-click the new display menu item, and then click &lt;b&gt;Save&lt;/b&gt;. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;After the new module &lt;b&gt;enum&lt;/b&gt; and display menu item are created, you can add them to the &lt;b&gt;Menus&lt;/b&gt; node.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;To Create a Menu for a New Module&lt;/strong&gt;&lt;/p&gt; &lt;ol&gt; &lt;li&gt;In the AOT, right-click the &lt;b&gt;Menus&lt;/b&gt; node, and then click &lt;b&gt;New Menu&lt;/b&gt;. A new menu displays under the &lt;b&gt;Menus&lt;/b&gt; node.  &lt;li&gt;Right-click the new menu, and then click &lt;b&gt;Properties&lt;/b&gt;.  &lt;li&gt;In the &lt;b&gt;Properties&lt;/b&gt; sheet, set the following properties. &lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Property&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Value&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Name&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to a label or name of the new module.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Label&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to a label that represents the text to display for the new menu in the client.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;In the AOT, right-click the new menu, point to &lt;b&gt;New&lt;/b&gt;, and then click &lt;b&gt;New Submenu&lt;/b&gt;. A submenu node displays under menu node created in the previous step.  &lt;li&gt;Right-click the new submenu node, and then click &lt;b&gt;Properties&lt;/b&gt;.  &lt;li&gt;In the &lt;b&gt;Properties&lt;/b&gt; sheet, set the following properties. &lt;/li&gt;&lt;/ol&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;1&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Property&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td&gt; &lt;p&gt;&lt;b&gt;Value&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Name&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to &lt;b&gt;Setup&lt;/b&gt; or another label that represents the text for the &lt;b&gt;Setup&lt;/b&gt; pane in the client.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;Label&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to &lt;b&gt;Setup&lt;/b&gt; or another label that represents the text for the &lt;b&gt;Setup&lt;/b&gt; pane in the client.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;NormalImage&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to 3478. This will display a gears icon for the setup pane.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;&lt;b&gt;ImageLocation&lt;/b&gt;&lt;/p&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot;&gt; &lt;p&gt;Set to &lt;b&gt;EmbeddedResource&lt;/b&gt;.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;ol start=&quot;start&quot;&gt; &lt;li&gt;In the AOT, right-click the &lt;b&gt;Setup&lt;/b&gt; node created in the previous step, point to &lt;b&gt;New&lt;/b&gt;, and then click &lt;b&gt;New Menu item&lt;/b&gt;. A new menu item displays under the &lt;b&gt;Setup&lt;/b&gt; node.  &lt;li&gt;Right-click the new menu item, and then click &lt;b&gt;Properties&lt;/b&gt;.  &lt;li&gt;In the &lt;b&gt;Properties&lt;/b&gt; sheet, set the &lt;b&gt;MenuItemName&lt;/b&gt; property to the display menu item created in the previous procedure.  &lt;li&gt;In the AOT, right-click the new menu item, and then click &lt;b&gt;Save&lt;/b&gt;. &lt;/li&gt;&lt;/ol&gt; &lt;p&gt;After the menu for the new module is created, you must add a reference to the menu in the &lt;b&gt;MainMenu&lt;/b&gt; node to display the menu in the client.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;To Add a Menu to the Client&lt;/strong&gt;&lt;/p&gt; &lt;ol&gt; &lt;li&gt;In the AOT, expand the &lt;b&gt;Menus&lt;/b&gt; node, right click &lt;b&gt;MainMenus&lt;/b&gt;, point to &lt;b&gt;New&lt;/b&gt;, and then click &lt;b&gt;Menu reference&lt;/b&gt;. The &lt;b&gt;Select: Menus&lt;/b&gt; window is displayed.  &lt;li&gt;In the &lt;b&gt;Select: Menus&lt;/b&gt; window, select the new module menu that you created in the previous procedure, and drag the menu to the &lt;b&gt;MainMenu&lt;/b&gt; node in the AOT.  &lt;li&gt;In the AOT, right-click the &lt;b&gt;MainMenu&lt;/b&gt; node, and then click &lt;b&gt;Save&lt;/b&gt;. &lt;/li&gt;&lt;/ol&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/5939276685102009247/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/07/how-to-create-new-module-with-workflow.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/5939276685102009247'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/5939276685102009247'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/07/how-to-create-new-module-with-workflow.html' title='How to: Create a New Module with Workflow [AX 2012]'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8725859366263791201.post-5006450290739618584</id><published>2014-07-17T14:57:00.001+03:00</published><updated>2014-07-17T14:57:30.355+03:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="AX 2012"/><category scheme="http://www.blogger.com/atom/ns#" term="Development"/><category scheme="http://www.blogger.com/atom/ns#" term="Workflow"/><title type='text'>How to: Enable a State Model for a Workflow Document [AX 2012]</title><content type='html'>&lt;p&gt;Workflow documents in a Microsoft Dynamics AX workflow must implement a state model to represent the state of a workflow, approval, or task for a workflow document in the application. For example, a workflow document in the NotSubmitted state can be changed to the Submitted state when a user clicks the Submit button. This section describes how to enable the state model for a workflow document by using a class or by creating a method on a table. &lt;/p&gt; &lt;p&gt;The following table contains recommended states. However, the needs of your application will determine what states are needed, validation type for state transitions, and how many states are needed. For more information, see Workflow Approval State Transitions post.&lt;/p&gt; &lt;table cellspacing=&quot;0&quot; cellpadding=&quot;2&quot; width=&quot;400&quot; border=&quot;0&quot;&gt; &lt;tbody&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot; width=&quot;200&quot;&gt;&lt;strong&gt;For the state of the&lt;/strong&gt;&lt;/td&gt; &lt;td valign=&quot;top&quot; width=&quot;200&quot;&gt;&lt;strong&gt;Use&lt;/strong&gt;&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt; &lt;td valign=&quot;top&quot; width=&quot;200&quot;&gt;Workflow document&lt;/td&gt; &lt;td valign=&quot;top&quot; width=&quot;200&quot;&gt; &lt;ul&gt; &lt;li&gt; &lt;p&gt;NotSubmitted&lt;/p&gt; &lt;li&gt; &lt;p&gt;Submitted&lt;/p&gt; &lt;li&gt; &lt;p&gt;ChangeRequested&lt;/p&gt; &lt;li&gt; &lt;p&gt;Returned&lt;/p&gt; &lt;li&gt; &lt;p&gt;Completed&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt; &lt;p&gt;Typically, the workflow state should be persisted in the root table of your workflow document data source. To add workflow state to a table, create an enum in the BaseEnums node of the Application Object Tree (AOT) that contains the workflow states shown in the previous table. The first enum defined should be the NotSubmitted enum, and this will also be the default setting in the table. After the enum is defined, drag the enum to the Fields node of the workflow document data source table. &lt;/p&gt; &lt;p&gt;After a state model is defined, you can enable forms and lists to work with workflow. For more information, see How to: Enable a Form or List for Workflow post. &lt;/p&gt; &lt;p&gt;&lt;img title=&quot;Note&quot; alt=&quot;Note&quot; src=&quot;http://i.msdn.microsoft.com/areas/global/content/clear.gif&quot;&gt;&lt;strong&gt;Note : &lt;/strong&gt;Workflow state can be implemented in many ways. The following procedure shows one way of performing this task. &lt;/p&gt; &lt;h5&gt;To create a state change manager class&lt;/h5&gt; &lt;ol&gt; &lt;li&gt; &lt;p&gt;In the AOT, expand the Classes node.&lt;/p&gt; &lt;li&gt; &lt;p&gt;Right-click the Classes node, and then select New Class. A class group displays under the Classes node.&lt;/p&gt; &lt;li&gt; &lt;p&gt;Right-click the new class, click Rename, and then enter a name for the class.&lt;/p&gt; &lt;li&gt; &lt;p&gt;Right-click the new class and then click New Method. A method node named method1 displays under the Classes node.&lt;/p&gt; &lt;li&gt; &lt;p&gt;Right-click method1 and then click Edit. Enter the following code for the started event method. &lt;/p&gt; &lt;p&gt;&lt;a&gt;X++&lt;/a&gt;&lt;/p&gt;&lt;pre&gt;public static void started(RecID _recID)&lt;br /&gt;{&lt;br /&gt;    &amp;lt;insert method here&amp;gt;&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;&lt;li&gt;&lt;br /&gt;&lt;p&gt;Repeat steps 4 and 5 for the remaining states.&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;h4&gt;&lt;br /&gt;&lt;p&gt;&lt;strong&gt;Example&lt;/strong&gt;&lt;/p&gt;&lt;/h4&gt;&lt;br /&gt;&lt;p&gt;&lt;a&gt;&lt;/a&gt;&lt;/p&gt;&lt;br /&gt;&lt;p&gt;The following code is part of the setWorkflowState on the PurchReqTable Table. This method sets the workflow state field in the table and updates the user interface with a user friendly status, and then updates the state in the database. &lt;/p&gt;&lt;br /&gt;&lt;p&gt;&lt;a&gt;X++&lt;/a&gt;&lt;/p&gt;&lt;pre&gt;static void setWorkflowState(RecId _purchReqRecId, PurchReqWorkflowState _purchReqWorkflowState)&lt;br /&gt;{&lt;br /&gt;    // Declare variables.&lt;br /&gt;    PurchReqTable purchReqTable;&lt;br /&gt;&lt;br /&gt;    ttsbegin;&lt;br /&gt; &lt;br /&gt;    // Selects the record to be updated based on the recId and then&lt;br /&gt;    // sets the workflow state. &lt;br /&gt;    purchReqTable = PurchReqTable::findRecId(_purchReqRecId, true);&lt;br /&gt;    purchReqTable.State = _purchReqWorkflowState;&lt;br /&gt;&lt;br /&gt;    // Based on the workflow state, the status in the user interface&lt;br /&gt;    // is updated with a user friendly status.&lt;br /&gt;    switch (_purchReqWorkflowState)&lt;br /&gt;    {&lt;br /&gt;        case PurchReqWorkflowState::Submitted:&lt;br /&gt;            purchReqTable.Status = PurchReqStatus::Submitted;&lt;br /&gt;            break;&lt;br /&gt;        case PurchReqWorkflowState::NotSubmitted:&lt;br /&gt;            purchReqTable.Status = PurchReqStatus::Draft;&lt;br /&gt;            break;&lt;br /&gt;        case PurchReqWorkflowState::Completed:&lt;br /&gt;            purchReqTable.Status = PurchReqStatus::Completed;&lt;br /&gt;            break;&lt;br /&gt;        case PurchReqWorkflowState::Returned:&lt;br /&gt;            purchReqTable.Status = PurchReqStatus::Rejected;&lt;br /&gt;            break;&lt;br /&gt;        case PurchReqWorkflowState::ChangeRequest:&lt;br /&gt;            purchReqTable.Status = PurchReqStatus::ChangeRequested;&lt;br /&gt;            break;&lt;br /&gt;    }&lt;br /&gt; &lt;br /&gt;    // Commits the state to the database. &lt;br /&gt;    purchReqTable.update();&lt;br /&gt; &lt;br /&gt;    ttscommit;&lt;br /&gt;}&lt;/pre&gt;  &lt;div class=&quot;blogger-post-footer&quot;&gt;&lt;script type=&quot;text/javascript&quot;&gt;&lt;!--
google_ad_client = &quot;ca-pub-0093924062064876&quot;;
google_ad_host = &quot;pub-1556223355139109&quot;;
/* TopBar-728x90 */
google_ad_slot = &quot;9731604514&quot;;
google_ad_width = 728;
google_ad_height = 90;
//--&gt;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;
src=&quot;http://pagead2.googlesyndication.com/pagead/show_ads.js&quot;&gt;
&lt;/script&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://sabermahdy.blogspot.com/feeds/5006450290739618584/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://sabermahdy.blogspot.com/2014/07/how-to-enable-state-model-for-workflow_17.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/5006450290739618584'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8725859366263791201/posts/default/5006450290739618584'/><link rel='alternate' type='text/html' href='http://sabermahdy.blogspot.com/2014/07/how-to-enable-state-model-for-workflow_17.html' title='How to: Enable a State Model for a Workflow Document [AX 2012]'/><author><name>Saber Mahdy</name><uri>http://www.blogger.com/profile/09115396477260365591</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>