I am totally baffled. I have created an excel workbook with multiple sheets, including monthly sheets, labeled Jan thru Dec. In my code I create backup exported CSV files of these sheets. Inspecting the CSV files shows all data is backed up correctly.
I then created code to import this data back in, should some corruption occur or be needed.
Each sheet contains multiple columns, several of which include monthly expenses. The first column E imports expense data properly which might show the expense of 54.40 as 54.4, and then I use some conversion code to convert the number to a 2 digit decimal prior to being copied to the monthly worksheet. Data is first imported to a buffer worksheet where this data conversion occurs and then copied to the appropriate worksheet.
Here is the strange thing that has me totally baffled, the column where I have a second group of expenses imported, always rounds the numbers and instead of appearing as say 54.4, it shows as 54.00, Were it 54.60 then it would be 55.00. This is prior to any conversion code.
I have tried multiple things, one of which is after I completely clear the buffer sheet before the next import, I also convert the entire sheet to text, so 54.4 should show in that other column as 54.4, but instead shows as a rounded number of 54.00 . I then added a specific code to convert just that column to text prior to import, but the import still shows all numbers in that column as rounded.
To add more confusion that has me baffled, the import works just find for sheets Jan thru May, but all imports for Jun thru Dec are rounded.
All months use the same code with the only differences are the CSV files for a particular sheet. In trouble shooting I took the May csv file and renamed it to several other months after June, each import is rounded even though the csv file worked fine in May.
One last thing, in troubleshooting, I also have deleted the Jun worksheet and recreated a new one, still the same problem occurs.
Hopefully, I have described that well enough and you can understand my frustration and confusion. Does anyone have any ideas that I might look at or what may be causing such a strange problem.
HELP?
Bookmarks