<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Nav developer's blog : Transformation</title><link>http://blogs.msdn.com/nav_developer/archive/tags/Transformation/default.aspx</link><description>Tags: Transformation</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Problems in transformation forms to pages using TransformationTools</title><link>http://blogs.msdn.com/nav_developer/archive/2009/09/14/problems-in-transformation-forms-to-pages-using-transformationtools.aspx</link><pubDate>Mon, 14 Sep 2009 15:10:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9894944</guid><dc:creator>gediminb</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/nav_developer/comments/9894944.aspx</comments><wfw:commentRss>http://blogs.msdn.com/nav_developer/commentrss.aspx?PostID=9894944</wfw:commentRss><description>&lt;P&gt;After Microsoft Dynamics NAV 2009 SP1 release more and more developers start using it and trying to&amp;nbsp;adopt existing solutions&amp;nbsp;for new 3tier environment.&lt;BR&gt;Most workload comes from trying to adopt current forms to new object - pages.&lt;BR&gt;Particularly transformation could be done by using TransformationTools (&lt;A href="http://msdn.microsoft.com/en-us/library/dd338789.aspx" mce_href="http://msdn.microsoft.com/en-us/library/dd338789.aspx"&gt;http://msdn.microsoft.com/en-us/library/dd338789.aspx&lt;/A&gt;), however it is not "best ever" and partners reporting&amp;nbsp;problems and require to fix it...&lt;/P&gt;
&lt;P&gt;But it isn't so easy...&lt;/P&gt;
&lt;P&gt;This tool is delivered to us from dev team and it&amp;nbsp;helps us to make transformation faster, but it is supplementary tool - we can use NAV without this tool and we can "convert " our solutions without it - do it manually.&lt;BR&gt;So "big thanks" to dev team for this tool, however we can't expect that dev team will fix all problems in tool with the same priority&amp;nbsp;as base products (Microsoft Dynamics NAV).&lt;/P&gt;
&lt;P&gt;And we can't expect fixes for problems related&amp;nbsp;to incorrect transformed statements - after transformation pages can't be compiled...&lt;BR&gt;Problem is in tool simplicity: it searches for text and convert it to another text. Converting rules are described in file CodeRules.txt (&lt;A href="http://msdn.microsoft.com/en-us/library/dd338843.aspx" mce_href="http://msdn.microsoft.com/en-us/library/dd338843.aspx"&gt;http://msdn.microsoft.com/en-us/library/dd338843.aspx&lt;/A&gt;).&lt;BR&gt;But simplicity is as strength as weakness of this tool - only text described in CodeRules.txt file will be converted, if there are any differences in text - transformation will be incorrect.&lt;BR&gt;For example:&lt;BR&gt;In form code we have statement:&lt;BR&gt;&lt;FONT face="Courier New"&gt;CurrForm.Number.UPDATEFONTBOLD(Number);&lt;BR&gt;&lt;FONT face=Arial&gt;Then after transformation on page will be created&amp;nbsp;new variable &lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;NumberEmphasize&lt;BR&gt;&lt;/FONT&gt;&lt;FONT face=Arial&gt;And statement will be converted to:&lt;BR&gt;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;NumberEmphasize := Number;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT face=Arial&gt;It is because&amp;nbsp;UPDATEFONTBOLD is not used in pages and must be removed.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;So far so good.&lt;BR&gt;Tranformation will be done correct for statements:&lt;BR&gt;&lt;FONT face="Courier New"&gt;CurrForm.Number.UPDATEFONTBOLD(Number1=Number);&lt;BR&gt;CurrForm.Number.UPDATEFONTBOLD(Number1&amp;gt;Number);&lt;BR&gt;&lt;/FONT&gt;and etc. because transformation rules are described in CodeRules.txt&lt;/P&gt;
&lt;P&gt;But transformation tool is looking for direct text fit to rules and will not transform text which is not described in Coderules.txt.&amp;nbsp;&lt;BR&gt;If code becomes little more complicated (not described the same&amp;nbsp;syntax as CodeRules)&amp;nbsp;- transformation tool capitulates.&lt;BR&gt;For example next code will not be transformed:&lt;BR&gt;&lt;FONT face="Courier New"&gt;CurrForm.Number.UPDATEFONTBOLD(Number1&amp;lt;Number);&lt;BR&gt;CurrForm.Number.UPDATEFONTBOLD(Number1=xRec.Number);&lt;BR&gt;CurrForm.Number.UPDATEFONTBOLD(xRec.Number1=Number);&lt;/FONT&gt;&lt;BR&gt;&lt;FONT face="Courier New"&gt;CurrForm.Number.UPDATEFONTBOLD(Number1=Number2=Number3);&lt;BR&gt;CurrForm.Number.UPDATEFONTBOLD(Number1=(Number+100));&lt;/FONT&gt;&lt;BR&gt;...&lt;BR&gt;&lt;BR&gt;Yes... We can make rules for these statements too&amp;nbsp;(dev team delivered rules file), but we will never describe everything what could be written by happy-creative developpers around the world...&lt;BR&gt;Maybe some rules could be&amp;nbsp;never used? Who&amp;nbsp;knows..?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;I can collect all requirements for CodeRules.txt and periodically release new one (fixed). Do you want to&amp;nbsp;order me do&amp;nbsp;it, let me know in comment to current post :) ...&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;&lt;EM&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Calibri','sans-serif'; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN; mso-bidi-theme-font: minor-bidi; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin" lang=EN&gt;&lt;FONT size=3&gt;These postings are provided "AS IS" with no warranties and confer no rights. You assume all risk for your use.&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0cm 0cm 10pt" class=MsoNormal&gt;&lt;EM&gt;&lt;SPAN style="FONT-STYLE: normal; FONT-FAMILY: 'Calibri','sans-serif'; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN; mso-bidi-theme-font: minor-bidi; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-bidi-font-style: italic; mso-bidi-font-weight: bold" lang=EN&gt;&lt;FONT size=3&gt;Gedas Busniauskas&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0cm 0cm 10pt" class=MsoNormal&gt;&lt;EM&gt;&lt;SPAN style="FONT-STYLE: normal; FONT-FAMILY: 'Calibri','sans-serif'; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN; mso-bidi-theme-font: minor-bidi; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-bidi-font-style: italic; mso-bidi-font-weight: bold" lang=EN&gt;&lt;FONT size=3&gt;Microsoft Lithuania&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/EM&gt;&lt;SPAN style="FONT-FAMILY: 'Calibri','sans-serif'; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN; mso-bidi-theme-font: minor-bidi; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-bidi-font-style: italic; mso-bidi-font-weight: bold" lang=EN&gt;&lt;BR&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'Calibri','sans-serif'; mso-ansi-language: EN" lang=EN&gt;&lt;FONT size=3&gt;Microsoft Customer Service and Support (CSS) EMEA&lt;/FONT&gt;&lt;/SPAN&gt;&lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="mso-ansi-language: EN-US" lang=EN-US&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/I&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9894944" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/nav_developer/archive/tags/C_2F00_AL/default.aspx">C/AL</category><category domain="http://blogs.msdn.com/nav_developer/archive/tags/Upgrade/default.aspx">Upgrade</category><category domain="http://blogs.msdn.com/nav_developer/archive/tags/NAV+2009/default.aspx">NAV 2009</category><category domain="http://blogs.msdn.com/nav_developer/archive/tags/Transformation/default.aspx">Transformation</category></item><item><title>NAV 2009 - How to - Simple Form Transformation</title><link>http://blogs.msdn.com/nav_developer/archive/2008/06/13/nav-2009-how-to-simple-form-transformation.aspx</link><pubDate>Fri, 13 Jun 2008 12:29:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8594284</guid><dc:creator>Lohndorf</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/nav_developer/comments/8594284.aspx</comments><wfw:commentRss>http://blogs.msdn.com/nav_developer/commentrss.aspx?PostID=8594284</wfw:commentRss><description>&lt;P&gt;This post describes the simplest possible way to transform a form into a page in NAV 2009. Both Pages and Transformation is documented in more details elsewhere. Here, I just want to make the simples possible example, just to get a simple form transformed into a simple page.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Prerequisites:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;You need to have at least a NAV 2009 classic client and the Transformation tool. To test the page, of course you also need the Rolebased client. But to just transform a form, you don't need it.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Import the tool:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;1)&amp;nbsp; Open a classic client, go to Object Designer and&amp;nbsp;import the files DevTool.fob and TIF.fob from the folder TransformationTool\TIF Editor\&lt;BR&gt;2)&amp;nbsp; Create a new form in NAV, as simple as possible. For example a Card form based on the customer table, with just a few fields on it. This is the form you want to transform.&lt;BR&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Setup and use the Transformation tool:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;3)&amp;nbsp; Run form 97000 "Transformation Forms"&lt;/P&gt;
&lt;P&gt;4)&amp;nbsp; Click Import -&amp;gt; "Import PageType - FormType mapping", and select the file TransformationTool\TIF Editor\FormToPagetypeMapping.txt.&lt;/P&gt;
&lt;P&gt;5)&amp;nbsp; Click Functions -&amp;gt; Get Forms. Filter on Type = Form, and ID = the new form, then click OK. This gets the form(s) that you want to transform.&lt;BR&gt;&lt;BR&gt;6)&amp;nbsp; In the FormType field, select "Card" ("Form with TabControl only and a source table").&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;BR&gt;&lt;STRONG&gt;Run the transformation:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;7)&amp;nbsp; Export the settings from form 97000: Click on Export -&amp;gt; "Transform Pages". You must export it to the TransformationTool folder, and it must be called TransformPages.xml.&lt;BR&gt;8)&amp;nbsp; From Object Designer, export the form (Tools -&amp;gt; Export) as xml.You must export it to the folder TransformationTool, and it must be called Forms.xml. &lt;/P&gt;
&lt;P mce_keep="true"&gt;You now have the form you want to transform, and the meta-data that tells the TranformationTool how to transform it.&lt;BR&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;9)&amp;nbsp; Run the file FormTransformation.exe from the TransformationTool folder. This generates a new file called Pages.xml. It also logs any progress or errors in the file Transformation.log.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Import the new page:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;10) Back in NAV (classic client): Go to Object Designer, and import the file Pages.xml, and then compile it.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;If all steps ran without any errors, you have now transformed your form into a page which can be displayed in the rolebased client.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;Lars Lohndorf-Larsen&lt;/P&gt;
&lt;P&gt;Microsoft Dynamics UK&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;Microsoft Customer Service and Support (CSS) EMEA&lt;/P&gt;
&lt;P&gt;These postings are provided "AS IS" with no warranties and confer no rights. You assume all risk for your use.&lt;/P&gt;&lt;/FONT&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=8594284" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/nav_developer/archive/tags/NAV+2009/default.aspx">NAV 2009</category><category domain="http://blogs.msdn.com/nav_developer/archive/tags/Transformation/default.aspx">Transformation</category></item></channel></rss>