• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 260
  • Last Modified:

Creating a 123 document from HTML

I have managed to setup my JSP so that when it is called, it automatically save the the data to a file.  I did this by setting the content type of the JSP as follows :

<%@page contentType="application/x-javascript; charset=ISO-8859-1"%>

This allows me to save the file.  I can then load it into Lotus 123.  Is there any way that I can bypass the having to save the file first, and just load the data straight into 123 from the browser ?

When I call this JSP, I want to be able to load the data straight into 123.

Any ideas, or is this impossible ?

Jim
0
jah99
Asked:
jah99
  • 5
  • 4
  • 2
  • +3
1 Solution
 
jimmackCommented:
Can you set the content type to something the your browser understands?

You can do this for Excel.
0
 
Dutch_guyCommented:
You should change your contentType to open directely in Lotus123.

If you would change it to:

application/vnd.ms-excel

it would open in Excel.

Or try the following (example is written in ASP):

Response.ContentType = "text/plain"
      Response.AddHeader "content-disposition", "attachment; filename=Batch-"test.csv"

You would have to change the .csv with the file extension Lotus123 uses.
0
 
jah99Author Commented:
Do you know how to create a file in a format the EXCEL or 123 understands.  If you just change the application to vnd.ms-excel is saves the file with the .xls extension, but when you try to open it, it doesn't recognise it as an excel document (I guess because it isn't).
0
Cloud Class® Course: CompTIA Healthcare IT Tech

This course will help prep you to earn the CompTIA Healthcare IT Technician certification showing that you have the knowledge and skills needed to succeed in installing, managing, and troubleshooting IT systems in medical and clinical settings.

 
jimmackCommented:
As far as I remember, you need to output the data as though you were going to display it in a table.

Just outputting the table with the vnd.excel MIME type should allow excel to open the result.
0
 
Dutch_guyCommented:
Excel should open the file.

Maybe you have an old version of Excel?

The thing is, the outputted Excel file is not a true Excel file. It''s just a HTML table which Excel can open in Excel.

 

0
 
jah99Author Commented:
Our company only has Excell Viewer, this may be why it doesn't work.   I need this to work with Lotus 123.
0
 
Dutch_guyCommented:
Try on your local computer to change what program a .xls extension should open.

If you change temporarily that a .xls file should be opened by Lotus123, you can see if Lotus123 opens the file immediately.
0
 
NetGrooveCommented:
You can test with this mime types:
application/x-lotus-123
application/lotus-123
application/vnd.lotus-1-2-3

But this will only work if browser has the 123 viewer or the application installed localy.

Good luck,
NetGroove

0
 
webwomanCommented:
What VERSION of 123? It's been around for a LONG time, and I wouldn't be surprised if some of the older file formats for it aren't compatible with Excel, and I really doubt it can read HTML.

If you're going to be generating things dynamically like this, you might want to consider changing/updating software.
0
 
jah99Author Commented:
Its release 9.6 which is reasonably new.  I've tried adding the 3 mime types as described by NetGrove.  None of them seem to save the file in a format which 123 can open.  I'm starting to think that Explorer and 123 are destined never to talk to each other.
0
 
jah99Author Commented:
I've been playing around.  

vnd.ms-excel  - opens and excel document
msword - opens a msword document

but

vnd.lotus-1-2-3 - does not open a 123 document
vnd.lotus-wordpro - does not open a wordpro doc.

Do you have to set up the mime types in explorer ?
 
0
 
Dutch_guyCommented:
As i mentioned in an earlier post, just change the mime type of a .xls file temporarily to open with Lotus123.

Then when you open the file with: "vnd.mx-excel" it should open in Lotus123.

Or you can try:

Response.AddHeader "content-disposition", "attachment; filename=test.csv"

Then replace test.csv with the extension Lotus123 uses.
0
 
NetGrooveCommented:
Hello Jim,

do you need more support on this?

0
 
jah99Author Commented:
I have tried the suggestions you put above ie using mime types of :

application/x-lotus-123
application/lotus-123
application/vnd.lotus-1-2-3

I do have 123 installed on my PC, and none of these work.  Any ideas ?

0
 
moduloCommented:
PAQed, with points refunded (500)

modulo
Community Support Moderator
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

  • 5
  • 4
  • 2
  • +3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now