Common a0 hex problem with exporting

Kisu
Member Posts: 381
This problem has been so common that it is just annoying.
When I export for example sales line fields with xmlport and there is quantity over 1000. The XML port adds thousand separator which in all windows and windows servers is char a0 hex no break space or something
Now when you look at the exported file all the integer and decimal fields that had value over thousand has that annoyance ](*,)
I've been thinking has anyone done a post codeunit that goes through the xml file or similar that destroys those a0 chars?
When I export for example sales line fields with xmlport and there is quantity over 1000. The XML port adds thousand separator which in all windows and windows servers is char a0 hex no break space or something
Now when you look at the exported file all the integer and decimal fields that had value over thousand has that annoyance ](*,)
I've been thinking has anyone done a post codeunit that goes through the xml file or similar that destroys those a0 chars?
K.S.
0
Answers
-
Hi Kisu
Normally I use a variable on such fields instead of the table field. On the DataItem- Export::OnAfterGetRecord() I use the format function with the desired format string on the var. Imho this is worth the few lines of code because you get much more control over the output.
Hope this helps.
Thomas0 -
Noo, I'm such an idiot, but of course format works with this ](*,)
Quantity - Export::OnBeforePassVariable()
bröblemsölved := FORMAT("Sales Line"."Quantity",0,'<Sign><Integer><Decimals,3>');
Thank youK.S.0 -
Hi Kisu
Welcome!
Don't be frustrated about the errors you have made, just be happy about the working solution0
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