Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Problem with Data Formatting

Hi ,
I tried what you suggested but it did not work
here the same code i used to laod a text file and sample data file i try
to load
string m_sTempCSVFilePath =
"D:\\abc_051b66ed-532c-4bab-a068-b63eb2c239d8.txt" ;

axSpreadsheet1.ActiveSheet.Cells.get_Item(1,1).
LoadText(m_sTempCSVFilePath,";",false,"' '");

axSpreadsheet1.Show ();

content of abc_051b66ed-532c-4bab-a068-b63eb2c239d8.txt file

CORE DESC;CORE
3" GRNSTRIPE NOTCHED;3GN
3" HVYWALL INSERTED;3HI
3" HVYWALL NO NOTCH;3HP
3" HVYWALL NOTCHED;3HN
3" MEDWALL NO NOTCH;3MP
3" REGWALL INSERTED;3RI
3" REGWALL NO NOTCH;3RP
3" REGWALL NOTCHED;3RN
3" THINWALL NO NOTCH;3TP
3" THINWALL NOTCHED;3TN
3"GRNSTRIPE NO NOTCH;3GP
4" MEDWALL NO NOTCH;4MP
4" REGWALL INSERTED;4RI
4" REGWALL NO NOTCH;4RP
4" REGWALL NOTCHED;4RN
5" MEDWALL NO NOTCH;5MP
5" MEDWALL NOTCHED;5MN
5" REGWALL INSERTED;5RI
5" REGWALL NO NOTCH;5RP
5" REGWALL NOTCHED;5RN
6" HVYWALL NO NOTCH;6HP
6" HVYWALL NOTCHED;6HN
6" REGWALL INSERTED;6RI
6" REGWALL NO NOTCH;6RP
6" REGWALL NOTCHED;6RN
723456789012345A;77W
8" REGWALL NO NOTCH;8RP
8" REGWALL NOTCHED;8RN
FHFHA;76P
NO CORE NEEDED;...
RWQRA;77B
STANDARD LINER CORE;STD


"BrianB" wrote in message
om...
Change the .csv file to .txt - you get more control over input.

Regards
BrianB
================================================



"amit" wrote in message

...
HI ,

I am using following function call to laod a csv file .

axSpreadsheet1.ActiveSheet.Cells.get_Item(1,1).
LoadText(m_sTempCSVFilePath,";",false,"");

axSpreadsheet1.Show();

The probelm I am getting is if data is something like 123456A or 73453P

then
it is taking it as time and showing me junk time like 8/8/1889 11:00AM

..

data like 123456B or 34567B is working fine . Also data like A234567A ,
123A456A is working fine .

If I open CSV file directly in excel it is working fine . Also import

is
working fine

Thanks in Advance

Regards

Amit



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel 2003 - Importing External Data - formatting problem? JamieB Excel Discussion (Misc queries) 0 March 4th 10 01:58 PM
Data connection and formatting problem Kathleen M. Excel Discussion (Misc queries) 0 August 3rd 09 11:22 PM
Formatting Problem John Calder New Users to Excel 2 April 6th 09 01:01 PM
Formatting problem? TwoDot Excel Discussion (Misc queries) 1 November 1st 07 01:27 PM
formatting problem srv5uk Excel Discussion (Misc queries) 1 July 7th 05 07:28 PM


All times are GMT +1. The time now is 04:46 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"