Convert a Code type to Text type

darmaa
Member Posts: 65
Hello All,
I have one problem. When I export a report to excel, G/L account with code data type is converted into text. but result is wrong. What should I do? Please help me?
Example:
G/L account No. is 2-2200(code type) -> exported to excel G/L account is 109606
I used to export into excel "excel buffer table"
I have one problem. When I export a report to excel, G/L account with code data type is converted into text. but result is wrong. What should I do? Please help me?
Example:
G/L account No. is 2-2200(code type) -> exported to excel G/L account is 109606
I used to export into excel "excel buffer table"
0
Comments
-
if your code to export the g/l account # are you using FORMAT?
kind of like
EnterCell(RowNo,ColumnNo,FORMAT("Account G/L"),FALSE,FALSE,'0');0 -
Thanks for reply Savatage,
I used that function. but last parameter is Underline format with boolean type. Why did you use it boolean type?
I used that:
EnterCell(RowNo,ColumnNo,FORMAT("Account G/L",2),FALSE,FALSE,FALSE);
EnterCell(RowNo,ColumnNo,text,bold,italic,underline);
but results is : 2-
I need '2-2200' result ](*,)
Regards,0 -
Put this "'" apostrophe symbol before your text. It will force excel to format filed as text. This is known issue, on some localized computers excel can format values by strange way.
Of course, this make sense if excel file will be used for human processing. If it will be read by another software - you'll got the "'YorValue" instead of "YorValue", but in Excel itself it will always looks and prints as "YorValue".0 -
Thanks ppavuk,
But How can I put this symbol before text? I used it that
EnterCell(Row, 6, format('AccountNo), FALSE, FALSE, FALSE);
but it has error.0 -
example
EnterCell(Row, Column, '''' + "Ship-to ZIP Code", FALSE, FALSE, FALSE);0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions