OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

How to check if a file can be open with Writer ?

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API
View previous topic :: View next topic  
Author Message
sbouchet
Newbie
Newbie


Joined: 11 Jan 2005
Posts: 2
Location: Nantes - France

PostPosted: Tue Jan 11, 2005 7:34 am    Post subject: How to check if a file can be open with Writer ? Reply with quote

Hi,

I am using OpenOffice to convert text files to .sxw files.

I am able to do so with .doc files, but i would like to do the same with every file supported by Writer.

How can i do that ???


Stephane
Back to top
View user's profile Send private message
SergeM
Super User
Super User


Joined: 09 Sep 2003
Posts: 3211
Location: Troyes France

PostPosted: Tue Jan 11, 2005 9:44 am    Post subject: Reply with quote

Probably in the same way you do it with doc file. Explain more precisely your problem : what language ...
_________________
Linux & Windows OOo3.0
UNO & C++ : WIKI
http://wiki.services.openoffice.org/wiki/Using_Cpp_with_the_OOo_SDK
In French
http://wiki.services.openoffice.org/wiki/Documentation/FR/Cpp_Guide
Back to top
View user's profile Send private message Visit poster's website
sbouchet
Newbie
Newbie


Joined: 11 Jan 2005
Posts: 2
Location: Nantes - France

PostPosted: Wed Jan 12, 2005 4:49 am    Post subject: Reply with quote

Well.
I am using Openoffice with JAVA , and it is a part of a J2EE application.
I try to upload a file via a form, convert this file with OpenOffice to a .sxw file, and then manipulate this file in order to extract it contents.

what i want to do is to use the API in order to know if the file uploaded can be open with OO..
Back to top
View user's profile Send private message
pitonyak
Administrator
Administrator


Joined: 09 Mar 2004
Posts: 3655
Location: Columbus, Ohio, USA

PostPosted: Wed Jan 12, 2005 7:13 am    Post subject: Reply with quote

From my book:
Quote:
OpenOffice.org has a type-detection mechanism to determine a documentís type when it is loaded. This mechanism has been reliable for the limited number of document types that I deal with daily. Sometimes, however, you must specify the filter name when importing a document.

Hopefully, the type detection will work with the file names and extensions that are provided. If not, then you will need to manually supply the filter name.

Look at the conversion stuff at: http://oooconv.free.fr/
_________________
--
Andrew Pitonyak
http://www.pitonyak.org/oo.php
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group