File format conversion on server

R

Richard Bond

I am producing office 2007 files (with no macros) directly on a webserver
from .net. I was then going to rely on users having the compatibility pack on
their machines to convert to whatever version of office they have. My boss
has now changed his mind and said that we should be able to give our users
the choice of formats. Is there recommended way of programmatically
converting from office 2007 format to say office 2003 format on a server?????
Is OMPM using the ofc appropriate for this environment?

regards,

Richard
 
C

crferguson

How about this: prior to actually creating the Excel file (assuming
that's the "Office 2007 files" you're talking about since you're
posting to an Excel group), have the user select the format they
want. Then use a conditional statement to save the Excel file in the
format you want. Of course, this suggestions makes a lot of
assumptions since you posted no code. For example I assume your using
an Excel.Application object. Something like the untested code here:

Private Sub SaveBook(sVer As String)
Dim e As Object
Dim w As Workbook

Set e = CreateObject("Excel.Application")
Set w = e.Workbooks.Add

Select Case sVer
Case "12.0"
w.SaveAs "C:\Temp\FileName.xls", xlExcel12
Case Else
w.SaveAs "C:\Temp\FileName.xls", xlExcel8
End Select

w.Close
Set w = Nothing
Set e = Nothing
End Select
End Sub
 
R

Richard Bond

apologies for the lack of clarity....I'm Ill at home Today

I'm producing excel files on demand on a webserver by creating the raw xml
required and packaging it up into the xlsx format which is fast and light on
server resources. As running excel on the server is generally ill advised
according to numerous MS articles, I need to be able to convert files to
older formats on demand as a second step (ideally not automating any office
program)

(There is a word conversion group but nothing for excel or office in general
as far as i can see)

regards,

Richard
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top