NetTalk Central

Author Topic: Exported xml not displaying correctly  (Read 5050 times)

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Exported xml not displaying correctly
« on: September 24, 2014, 12:13:00 PM »
If I export the screen displayed in 1.png I get the attached txt file (rename to .xml). 2.png shows that the Account Number field is is truncated (actually rounded off to the first 15 digits). However viewing the xml file with notepad shows the full, untruncated value for account number.
Is there anything that can be done to display the correct value?



[attachment deleted by admin]
« Last Edit: September 24, 2014, 12:15:34 PM by terryd »
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186

kevin plummer

  • Hero Member
  • *****
  • Posts: 1195
    • View Profile
    • Production Accounting and Software Payroll
Re: Exported xml not displaying correctly
« Reply #1 on: September 24, 2014, 04:22:10 PM »
Hi terry,

Excel won't display "big" numbers. You will need store the value as Text which can be done by putting <39> before the account number but there may be a more elegant way in the method. You'll need to work out where to do this in the XML file process.

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Re: Exported xml not displaying correctly
« Reply #2 on: September 24, 2014, 09:33:17 PM »
Yeah just about what I thought. The account number itself is obviously a string but excel assumes any froup of digits is numeric.
Hopefully Bruce can advise me of where I can do this as part of the export otherwise I'll need to do it via a process export to excel
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Exported xml not displaying correctly
« Reply #3 on: September 25, 2014, 10:27:49 PM »
Hi Terry,

There's a specific solution (ie handling numbers > 15 digits) and a generic solution (allowing the programmer to specify the type.)

In your case I'd like you to try the specific solution, and let me know if it works please.

in xFiles.clw

xCell.SetCell method

search for

if not omitted(p_data) and numeric(p_data)

and replace with

if not omitted(p_data) and numeric(p_data) and len(clip(p_data)) < 16


The generic solution is a lot more invasive, and I would need to think before implementing that.

Cheers
Bruce