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

Reading in all the text in VB

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


Joined: 17 Feb 2006
Posts: 3

PostPosted: Fri Feb 17, 2006 3:23 am    Post subject: Reading in all the text in VB Reply with quote

Hi i'm very new to this, i been looking on the forms for ages and havn't found a solution, so i wonder if anyone can point me in the right direction?

I'm trying to read in all the text from a doc file using the open office writer and VB 6. i have managed to open the file but no idea how to get the text from it Sad .
can someone show me how it's done?
Back to top
View user's profile Send private message
wessen
Newbie
Newbie


Joined: 17 Feb 2006
Posts: 3

PostPosted: Fri Feb 17, 2006 7:26 am    Post subject: Reply with quote

anyone? i just need to know the sub properties?

for example

Set oSearch = odoc.createSearchDescriptor
Set oResult = odoc.findAll(oSearch)
Dim text: text = oResult.? what goes here i have no idea i tryed gettext() text and everything i could find. i tryed looking for a guid that lists the sub properties, but still failed to find anything Crying or Very sad
Back to top
View user's profile Send private message
B Marcelly
Super User
Super User


Joined: 12 May 2004
Posts: 1453
Location: France

PostPosted: Fri Feb 17, 2006 8:39 am    Post subject: Reply with quote

You won't get anywhere guessing like this. You should learn API programming with Basic. The examples can easily be used in VB6+COM.
Read a good book or StarOffice 7 Software Basic Programmer's Guide. There is a link to it and other references at http://api.openoffice.org/TipsAndTricks/external.html
_________________
Bernard

OpenOffice.org 1.1.5 fr / Apache OpenOffice 4.0.1 / LibreOffice 4.1.0
MS-Windows 7 Home SP1
This forum is spammed, use instead Apache OpenOffice forums
Back to top
View user's profile Send private message Visit poster's website
wessen
Newbie
Newbie


Joined: 17 Feb 2006
Posts: 3

PostPosted: Mon Feb 20, 2006 6:30 am    Post subject: Reply with quote

well the good news i got what i wanted done by converting the file to html, then processing it form there using xml. the bad news is i still don't know how to do the first part. it's over now anyway thanks B Marcelly for link it may come in handy
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: Mon Feb 20, 2006 7:15 am    Post subject: Reply with quote

See also :
A tutorial for Programming OpenOffice.org with Visual Basic http://www.oooforum.org/forum/viewtopic.phtml?t=11854&highlight=
_________________
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
pitonyak
Administrator
Administrator


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

PostPosted: Mon Feb 20, 2006 9:28 am    Post subject: Reply with quote

Unless you learn at leat a little about what is going on, nothing will be useful....
Code:
MsgBox ThisComponent.getText().getString()

_________________
--
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