Title: Message
I am trying to make a comma and also another on is fixed length TEXt files so I thought AsciIO would be fine....
 
-----Original Message-----
From: Axapta-Knowledge-Village@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Subrahmanyam, Mamidi
Sent: 31 August 2005 21:45
To: Axapta-Knowledge-Village@yahoogroups.com
Subject: RE: [Axapta-Knowledge-Village] ASCIIIO fieltype

Hi James,
 
I was also using terminal sever.
Are you trying to write Binarydata into a file using AsciiIO class?.
or are you trying to write it an excel file?. ( or CSV )
 
 
Fortunately, I didn;t experience this kind of settings problem.
 
Let us hope someone had similar exp and may share their  exp.
 
But I feel the datatype ( Ascci or binary) is what you are having problems.
BTW, do you have other way to accomplish this?.
 
Like did you try uing Textbuffer, CommaIO, BinaryIo etc etc....
 
best of luck.
thanks,
subbu
 
 
 
 
 
 
 
 


James Flavell <[EMAIL PROTECTED]> wrote:
Thanks Subbu,
 
What you write should work but I am still struggling ... I have tried everything in the type and delimiter but still I have the problem.
 
Can anyone help me, the machine I run the export on is a Windows terminal 2003 server.  When I open the data import wizard in excel the file orgin type is 'MS-DOS(PC-8)' where usually I think it is 'Windows ANSI' on my win2000 notebook.  Is there possibly some setting on the server (Axapta or Termainal server) that is causing this?
 
If I take the file, open with a text editor and then save it with a different name.  When I compare the two files with a file compare program then the two files do show up as different but when I use a hex editor and look inside everything is exactly the same with \r\n (0d 0a) at the end of everyline.
 
Does anyone know does excel add its own characters when opening a file?
 
Help please before I pull out all more hair or put my fist through the monitor!!!
James
 
-----Original Message-----
From: Axapta-Knowledge-Village@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Subrahmanyam, Mamidi
Sent: 30 August 2005 11:15
To: Axapta-Knowledge-Village@yahoogroups.com
Subject: Re: [Axapta-Knowledge-Village] ASCIIIO fieltype

Hi James,
Here is my exp. I uploaded around 500K items using a job using ASCII file formatted with 'tab' limited filed file with every record as new line.
 
Here is a small piece for in reading a file with columns seperated with a tab.
 
  file = new AsciiIo("X:\\subbu\\ITEM\\204_MRO_IC.txt","R");
  file.inFieldDelimiter('\t');
  file.inRecordDelimiter('\r\n');
 
So, I think when you want a output file with tab limited, I think I may need to change it to.
 
file = new AsciiIo("X:\\subbu\\ITEM\\204_MRO_IC.txt","W");
  file.outFieldDelimiter('\t');
  file.outRecordDelimiter('\r\n');
 
 
I am not sure if this helps.
 
Good Luck
thanks,
subbu
 


James Flavell <[EMAIL PROTECTED]> wrote:
Hi I am using the Axapta ASCIIIO file type for the first time but getting problems with carraige return/linefeed.
 
The file I create looks okay in notepad but in excel it has a blank line after every data line.
 
What should the outRecordDelimiter be set as?
I tried not setting, \r\n and also \n but they all seem to have the same problem....
 
Below is my code, should I be using mode T or B? Supposedly this is a fixed length file...
 
    txtFile =   new AsciiIO(this.generate_FullPathFileName(),"wt");
//    txtFile.outRecordDelimiter('\r\n');
//    txtFile.outRecordDelimiter('\n');
 
Thanks
James
 


Start your day with Yahoo! - make it your home page


Start your day with Yahoo! - make it your home page

Sharing the knowledge on Axapta.



SPONSORED LINKS
Axapta Business finance course Business finance online course
Business finance class Business finance schools Business finances


YAHOO! GROUPS LINKS




Reply via email to