There is quite much possible with the FORMAT-statement. Just look for the format statement and property in the help.
Here are some examples of how to use the Format property:
Choosing a standard format:
Use the Standard Format attribute to select one of the standard formats (these are listed at the end of this Help topic).
For example, <Standard Format,5> will select Standard Format 5.
Using a standard format with an attribute:
<Precision,2:3><Standard Format,0> will use Standard Format 0 and will format the data with a minimum of 2 and a maximum of 3 decimal places. See also the DecimalPlaces property. If you do not specify any precision the form will use the precision specified in the Decimal Places property of the corresponding field in the table.
Building a Format
You can create your own formats by using Chars (which will be displayed literally), Fields (to choose specific components of a value, for example the year-part of a date) and Attributes (for example to select which character to use as a filler).
For example, a text box based on a source expression of the Date data type, that uses the following format string:
Instead of spending lots of time to figure out how to write some critical basic functions I would prefer to figurre out how Navision handle them now. As much as I can. Until today, there are many many useful functions which are integrated into standard codeunits, we can use them as much as we can and spend time on business logic coding. Actually, "reading codeunits" is very helpful for me, I found lots of useful staff within Navision.
Comments
Text : Txt
Txt := Format(Dt); -- this code will convert Date field to Text.
Mahesh Jain
mahesh@reliconservices.com
mahesh instruction fits with each datatype
O.T.:
"Never memorize what you can easily find in a book".....Or Mibuso
My Blog
Eric Wauters
MVP - Microsoft Dynamics NAV
My blog
DO NOT forget standard codeunit 6201 Conventions, You will get a shock
MCP - MBS Navision
jle@naviworld.com
And what do you mean?
Eric Wauters
MVP - Microsoft Dynamics NAV
My blog
wth, could not they at least check for MS SQL option with RECORDLEVELLOCKING function before setting 1753.01.01 ?
Good Luck,
MCP - MBS Navision
jle@naviworld.com
http://www.packtpub.com/Microsoft-.NET- ... ision/book
Eric Wauters
MVP - Microsoft Dynamics NAV
My blog