Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Formatting in Excel from FoxPro
Message
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Environment versions
Visual FoxPro:
VFP 9 SP2
Network:
Windows 2008 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01519316
Message ID:
01519318
Views:
71
This message has been marked as the solution to the initial question of the thread.
>I noticed that an Employer ID of 0003 became 3 in my EXCEL Automation output. I know that I can go to Format / Format Cells and pick TEXT for the style of the Cell, but how do I ensure that a set of numbers stays as characters from within Visual FoxPro when writing to an EXCEL file?


Prepend a single quote to the value
   cell.Value = "'" + '00003'
Gregory
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform