- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-12-2015 06:57 AM
In report module, how can export in .txt file. No excel, no csv, only in .txt file
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-07-2019 01:09 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-12-2015 09:43 AM
To my knowledge, you cannot natively export to a pure .txt format. I suppose you could export to csv or excel and then try to export to text from there.
May I ask what the use case is for exporting to a txt file?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-12-2015 10:57 AM
Hi.
Thanks for your response.
But I want to export like a dump from mainframe.
What do you think please about scripting below, I found it but not try.
Does it possible to apply on export list ?
Thanks,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-12-2015 11:44 AM
I don't see any script attached or included with your post. I do understand that you are trying to export to a pure text file, similar to how some mainframes are able to.
The challenge that I have is that I just do not understand the use case. What do you then do with the text file? At that point it is not going to be human readable to any functional degree. Are you then feeding that document into another system for further processing? Or, perhaps feeding it into an application for accessibility needs, such as a text-to-voice application?
If you are feeding it into another system, does that system have APIs or the ability to connect with a web service?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-13-2015 05:24 AM
Hi.
The script was an image pasted. Here the text:
**************************************************************
I want to export like a dump from mainframe.
What do you think please about scripting below, I found it but not try.
Does it possible to apply on export list ?
1. var myFields = new Packages.com.glide.choice.ChoiceList();
2. myFields.add('first_name');
3. myFields.add('last_name');
4.
5. var myQuery='first_name=Fred';
6.
7.
var c = new Packages.com.glide.generators.CSVExporter('sys_user', myQuery, myFields);
8. var outFile = new Packages.java.io.File('/tmp/pat.txt');
9. var outStream = new Packages.java.io.FileOutputStream(outFile);
10. c.generate(outStream);
11. outStream.close();
Thanks