Re: [libreoffice-users] Re: using fields in a text document

2011-06-24 Thread lee
Alexander Thurgood  writes:

> Le 24/06/11 15:13, lee a écrit :
>
> Hi Lee,
>
>
>> Now I would like to make it so that I can press a button and be
>> presented with a form or the like that lets me fill in the variable
>> data, inserts the data at the appropriate places into the document,
>> saves the document to a file I specify and exports the document as PDF
>> with a password for access rights to the PDF file set.
>> 
>> How do I do that? Does it take some kind of advanced programming?
>> 
>
> If you don't want to go down the mailmerge route, then the answer is
> yes, you will need to be able to program it in Basic or some other
> scripting language that LibO knows how to interpret (Javascript or
> Python for example) and can bind with UNO dialog components.

Well, I'm thinking about using it, I just don't see yet how I could make
it really useful.

> Really, the simplest way would be to use a Calc spreadsheet to hold the
> data, and then bind those fields to your text document.

That is exactly what I'm trying to avoid. The workflow is like:


while(webpages) {

  check out the web page

  decide whether to send my document or not

  if(I send it) {
create a new directory to save the document in // this is already
   // automated by a 
   // shell script

paste a unique reference number generated by the shell script into
the document

copy and paste some data like a company name and address and a
persons name into the document

adjust the salutation as needed

go to another place in the document and enter the companys name and
city

save the document in the directory created by the shell script with
a meaningful file name (like "-")

export the document as pdf with a permissions password set

create an email by editing an email template appropriately to send
the pdf file by email

save the webpage in the same directory as the LO document

make a note in a text file that the document was sent in response to
the particular web page
  }
}

I can hear this crying for (at least some more) automation from 10 miles
away ...

It is possible to gather the data inserted into the document in
advance. The problem is that when I do that, I think it would become
rather difficult to keep track of what happens. And I need to keep track
of what happens because I have to do some of the steps manually because
it would be too much effort to automate all of them.

Perhaps there is way to make things easier that I just don't see? I'm
free to change the workflow in whatever way I like, only the outcome
needs to be the same.

> Even here though, if you want it to automatically export your filled
> in text document as a password protected PDF, you will need to learn
> some kind of programming to automate it.

Hm, I think someone here posted about commandline options for converting
to PDF. Perhaps I can use those ...

> Alternatively, use text placeholders in your document, but this will
> force you to type in each time for each and every different data set.

Placeholders ... can you address placeholders from the commandline? For
example, I'd create a document that has 5 placeholder fields and tell LO
on the commandline to process the document so that the data for the
fields I supply on the commandline is inserted into the document. Then
the document is converted to a PDF file.

Or can I use sed to modify the content.xml file and then use LO
commandline options to turn the file into a PDF? If that's possible, I
could make a script to produce the PDF files I need automatically ...

-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted


Re: [libreoffice-users] Re: using fields in a text document

2011-06-24 Thread Frieder

Am 24.06.2011 18:28, schrieb lee:

Alexander Thurgood  writes:


Le 24/06/11 15:13, lee a écrit :

Hi Lee,



Now I would like to make it so that I can press a button and be
presented with a form or the like that lets me fill in the variable
data, inserts the data at the appropriate places into the document,
saves the document to a file I specify and exports the document as PDF
with a password for access rights to the PDF file set.

How do I do that? Does it take some kind of advanced programming?


If you don't want to go down the mailmerge route, then the answer is
yes, you will need to be able to program it in Basic or some other
scripting language that LibO knows how to interpret (Javascript or
Python for example) and can bind with UNO dialog components.

Well, I'm thinking about using it, I just don't see yet how I could make
it really useful.


Really, the simplest way would be to use a Calc spreadsheet to hold the
data, and then bind those fields to your text document.

That is exactly what I'm trying to avoid. The workflow is like:


while(webpages) {

   check out the web page

   decide whether to send my document or not

   if(I send it) {
 create a new directory to save the document in // this is already
// automated by a
// shell script

 paste a unique reference number generated by the shell script into
 the document

 copy and paste some data like a company name and address and a
 persons name into the document

 adjust the salutation as needed

 go to another place in the document and enter the companys name and
 city

 save the document in the directory created by the shell script with
 a meaningful file name (like "-")

 export the document as pdf with a permissions password set

 create an email by editing an email template appropriately to send
 the pdf file by email

 save the webpage in the same directory as the LO document

 make a note in a text file that the document was sent in response to
 the particular web page
   }
}

I can hear this crying for (at least some more) automation from 10 miles
away ...

This is crying for for some macros and for a database.
if you already know how to  use shell scripts, it's not hard to learn to 
program some macros.

and you can use command-line commands inside macros as well.
so you can integrate your scripts into the macros. ( Coder : shell ( 
command-line command , options , ,).
If you make a database in Base with a table(or better more, with are 
linked together)  with a column  for each entry you have to make in the 
writer-document (and some more for information and ID) ,
you can connect the fields (columns) to text-boxes in the document (with 
invisible borders).

create a form (in Base), to insert the new data.
Then you need a macro to
Sub.

-create a new directory to save the document in
-paste a unique reference number generated by the shell script (bette the 
macro)
 into the document (better the database)
-save the document in the directory created by the macro with
 a meaningful file name (like "-"(use the database 
to find this name)
-export the document as pdf
-save the PDF with a permissions password (schell command inside the Macro)
-create an email by editing an email template(using again the data from the 
database) to send
 the pdf file by email
-save the webpage in the same directory as the LO document
-make a note in the database that the document was sent in response to
 the particular web page
End Sub

regards
Frieder



It is possible to gather the data inserted into the document in
advance. The problem is that when I do that, I think it would become
rather difficult to keep track of what happens. And I need to keep track
of what happens because I have to do some of the steps manually because
it would be too much effort to automate all of them.

Perhaps there is way to make things easier that I just don't see? I'm
free to change the workflow in whatever way I like, only the outcome
needs to be the same.


Even here though, if you want it to automatically export your filled
in text document as a password protected PDF, you will need to learn
some kind of programming to automate it.

Hm, I think someone here posted about commandline options for converting
to PDF. Perhaps I can use those ...


Alternatively, use text placeholders in your document, but this will
force you to type in each time for each and every different data set.

Placeholders ... can you address placeholders from the commandline? For
example, I'd create a document that has 5 placeholder fields and tell LO
on the commandline to process the document so that the data for the
fields I supply on the commandline is inserted into the document. Then
the document is converted to a PDF file.

Or can I use sed to modify the content.xml file and then u

Re: [libreoffice-users] Re: using fields in a text document

2011-06-24 Thread planas
Hi Lee

On Fri, 2011-06-24 at 16:18 +0200, Alexander Thurgood wrote:

> Le 24/06/11 15:13, lee a écrit :
> 
> Hi Lee,
> 
> 
> > Now I would like to make it so that I can press a button and be
> > presented with a form or the like that lets me fill in the variable
> > data, inserts the data at the appropriate places into the document,
> > saves the document to a file I specify and exports the document as PDF
> > with a password for access rights to the PDF file set.
> > 
> > How do I do that? Does it take some kind of advanced programming?
> > 
> 
> If you don't want to go down the mailmerge route, then the answer is
> yes, you will need to be able to program it in Basic or some other
> scripting language that LibO knows how to interpret (Javascript or
> Python for example) and can bind with UNO dialog components.
> 
> Really, the simplest way would be to use a Calc spreadsheet to hold the
> data, and then bind those fields to your text document. Even here
> though, if you want it to automatically export your filled in text
> document as a password protected PDF, you will need to learn some kind
> of programming to automate it.
> 
> Alternatively, use text placeholders in your document, but this will
> force you to type in each time for each and every different data set.
> 
> 
> Alex
> 
> 

Another possibility that works very well when you need a document that
needs the same type of content is to use an Input Field.

To do so:

INSERT>>FIELDS>>OTHER (or CTRL F2) click on Functions Tab then click on
Input. Enter the name of the field in the Reference Box. Click Insert
and Dialog Box opens. Your cursor should be in the large empty box, if
not, click on the large box. Type the place holder text you want that
will displayed when SHOW FIELDS is active. Click OK then click Close.

Do this for every location you want insert text. I would save this
document as a template. 

When you open this template Writer will ask you to enter data for each
field in the order they were created.

This method works well when you have only a few documents you want to
create each time.

-- 
Jay Lozier
jsloz...@gmail.com

-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted


Re: [libreoffice-users] Re: using fields in a text document

2011-06-24 Thread Frieder

Am 24.06.2011 18:28, schrieb lee:

Alexander Thurgood  writes:


Le 24/06/11 15:13, lee a écrit :

Hi Lee,



Now I would like to make it so that I can press a button and be
presented with a form or the like that lets me fill in the variable
data, inserts the data at the appropriate places into the document,
saves the document to a file I specify and exports the document as PDF
with a password for access rights to the PDF file set.

How do I do that? Does it take some kind of advanced programming?


If you don't want to go down the mailmerge route, then the answer is
yes, you will need to be able to program it in Basic or some other
scripting language that LibO knows how to interpret (Javascript or
Python for example) and can bind with UNO dialog components.

Well, I'm thinking about using it, I just don't see yet how I could make
it really useful.


Really, the simplest way would be to use a Calc spreadsheet to hold the
data, and then bind those fields to your text document.

That is exactly what I'm trying to avoid. The workflow is like:


while(webpages) {

   check out the web page

   decide whether to send my document or not

   if(I send it) {
 create a new directory to save the document in // this is already
// automated by a
// shell script

 paste a unique reference number generated by the shell script into
 the document

 copy and paste some data like a company name and address and a
 persons name into the document

 adjust the salutation as needed

 go to another place in the document and enter the companys name and
 city

 save the document in the directory created by the shell script with
 a meaningful file name (like "-")

 export the document as pdf with a permissions password set

 create an email by editing an email template appropriately to send
 the pdf file by email

 save the webpage in the same directory as the LO document

 make a note in a text file that the document was sent in response to
 the particular web page
   }
}

I can hear this crying for (at least some more) automation from 10 miles
away ...

It is possible to gather the data inserted into the document in
advance. The problem is that when I do that, I think it would become
rather difficult to keep track of what happens. And I need to keep track
of what happens because I have to do some of the steps manually because
it would be too much effort to automate all of them.

Perhaps there is way to make things easier that I just don't see? I'm
free to change the workflow in whatever way I like, only the outcome
needs to be the same.


Even here though, if you want it to automatically export your filled
in text document as a password protected PDF, you will need to learn
some kind of programming to automate it.

Hm, I think someone here posted about commandline options for converting
to PDF. Perhaps I can use those ...


ther is a Basic example for a macro to export to PDF
its not clean code, but it should work:

|sub export_to_PDF
rem define variables
dim document   as object
dim dispatcher as object
rem get access to the document
document   = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
dim args1(3) as new com.sun.star.beans.PropertyValue
args1(0).Name = "URL"
args1(0).Value = "file:///G:/test/test.pdf" ' you can use a variable to 
hold the path

args1(1).Name = "FilterName"
args1(1).Value = "calc_pdf_Export"
args1(2).Name = "FilterData"
args1(2).Value = 
Array(Array("UseLosslessCompression",0,true,com.sun.star.beans.PropertyState.DIRECT_VALUE),_

Array("Quality",0,90,com.sun.star.beans.PropertyState.DIRECT_VALUE),_
Array("ReduceImageResolution",0,false,com.sun.star.beans.PropertyState.DIRECT_VALUE),_
Array("MaxImageResolution",0,300,com.sun.star.beans.PropertyState.DIRECT_VALUE),_
Array("UseTaggedPDF",0,false,com.sun.star.beans.PropertyState.DIRECT_VALUE),_
Array("ExportNotes",0,false,com.sun.star.beans.PropertyState.DIRECT_VALUE),_
Array("UseTransitionEffects",0,true,com.sun.star.beans.PropertyState.DIRECT_VALUE),_
Array("IsSkipEmptyPages",0,false,com.sun.star.beans.PropertyState.DIRECT_VALUE),_
Array("FormsType",0,1,com.sun.star.beans.PropertyState.DIRECT_VALUE),_
Array("Selection",0,,com.sun.star.beans.PropertyState.DIRECT_VALUE))
args1(3).Name = "SelectionOnly"
args1(3).Value = true
dispatcher.executeDispatch(document, ".uno:||ExportDirectToPDF||", "", 
1, args1())

end sub

if you want I can translate this code in clean code without using the 
dispatcher


regards frieder
|

Alternatively, use text placeholders in your document, but this will
force you to type in each time for each and every different data set.

Placeholders ... can you address placeholders from the commandline? For
example, I'd create a document that has 5 placeholder fields and tell LO
on the commandline to process the documen

Re: [libreoffice-users] Re: using fields in a text document

2011-06-24 Thread lee
Frieder  writes:

> Am 24.06.2011 18:28, schrieb lee:
>>
>> while(webpages) {
>>
>>check out the web page
>>
>>decide whether to send my document or not
>>
>>if(I send it) {
>>  create a new directory to save the document in // this is already
>> // automated by a
>> // shell script
>>
>>  paste a unique reference number generated by the shell script into
>>  the document
>>
>>  copy and paste some data like a company name and address and a
>>  persons name into the document
>>
>>  adjust the salutation as needed
>>
>>  go to another place in the document and enter the companys name and
>>  city
>>
>>  save the document in the directory created by the shell script with
>>  a meaningful file name (like "-")
>>
>>  export the document as pdf with a permissions password set
>>
>>  create an email by editing an email template appropriately to send
>>  the pdf file by email
>>
>>  save the webpage in the same directory as the LO document
>>
>>  make a note in a text file that the document was sent in response to
>>  the particular web page
>>}
>> }
>>
>> I can hear this crying for (at least some more) automation from 10 miles
>> away ...
>>

[...]

> ther is a Basic example for a macro to export to PDF
> its not clean code, but it should work:

[...]

>
> if you want I can translate this code in clean code without using the
> dispatcher

Hm, I just tried out the macro recorder and recorded a macro that
exports my document as PDF. It looks very much like the one you
posted. It even stores the permissions password I entered in readable
form.

It strikes me odd that I shall have to learn another programming
language to do something this simple ... Anyway, what bothers me the
most at the moment is this bug with all the fields disappearing from
data sources: Even if I don't enter more than one data set into a data
source through a form and some programming, I won't get anywhere when
the fields of the data source eventually disappear.

Hm. I can't even register a data source as described in the
documentation[1]. The only available selection the wizard offers is
"Other external data source", and selecting that and trying to get to
the next page of the wizard brings up an error message:

,
| SQL Status: HY000
| 
| The connection to the external data source could not be established. No
| SDBC driver was found for the given URL.
| 
| A connection for the following URL was requested
| "sdbc:address:evolution:local".
`

So is it trying to use some data from Evolution? I don't have Evolution
installed.

Hm. I have created a database to use instead of a spreadsheet. When I'm
trying to mail the document to myself as PDF, I can specify "Properties"
in the mailmerge wizard. There I could apparently add a text message so
that the PDF is sent as an attachment to it. I could use that to mail
the PDF documents to myself with the reference number in the text part
for easy further processing, or I might even be able to send them
without any further processing.

Unfortunately, LO crashes when I try to send the message:


,
| X Error: BadMatch (invalid parameter attributes) 8
|   Major opcode: 42 (X_SetInputFocus)
|   Resource id:  0x5001822
| #
| # A fatal error has been detected by the Java Runtime Environment:
| #
| #  SIGSEGV (0xb) at pc=0x7f2cabeb5751, pid=21389, tid=139829845436192
| #
| # JRE version: 6.0_18-b18
| # Java VM: OpenJDK 64-Bit Server VM (16.0-b13 mixed mode linux-amd64 )
| # Derivative: IcedTea6 1.8.7
| # Distribution: Debian GNU/Linux unstable (sid), package 6b18-1.8.7-4
| # Problematic frame:
| # C  [libuno_sal.so.3+0x43751]  rtl_uString_release+0x1
| #
| # An error report file with more information is saved as:
| # /home/lee/hs_err_pid21389.log
| #
| # If you would like to submit a bug report, please include
| # instructions how to reproduce the bug and visit:
| #   http://icedtea.classpath.org/bugzilla
| #
| 
| [error occurred during error reporting , id 0xb]
`


It doesn't seem worthwhile to put any effort into programming when
everything that uses datasources is buggy in one way or another,
especially since the mailmerge tool would do a lot of what I want if it
would work.

So what's the alternative to LO? Can I convert my document to koffice?
Is koffice any better?

LaTeX would be my favourite choice; it's only too long ago I used it
last time, and when I tried more recently, I didn't manage to figure out
how to create tables that go across several pages and contain
tables. Perhaps I should give that another try; the result would look
much better anyway ...


[1]: 
http://wiki.documentfoundation.org/cgi_img_auth.php/0/05/0211WG3-UsingMailMerge.pdf

-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting gui

Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread Frieder

Am 25.06.2011 00:53, schrieb lee:
Hello Lee

Frieder  writes:

[...]

ther is a Basic example for a macro to export to PDF
its not clean code, but it should work:
[...]

if you want I can translate this code in clean code without using the
dispatcher

Hm, I just tried out the macro recorder and recorded a macro that
exports my document as PDF. It looks very much like the one you
posted. It even stores the permissions password I entered in readable
form.
Yes I also did it with the macro recorder, but I can translate it to 
better code if you want (the dispatcher is not reliable ).

It strikes me odd that I shall have to learn another programming
language to do something this simple ...

What programming languages do you  know?
You can write macros in Basic, Python , JavaScript , and even in C, C++ 
,Java and some more ,if you know how to call the Uno API .
But Basic is really simple. (No useless bracket for example. And how to 
write a " for loop " or something similar easy is not hard to learn in 
any language.)
The Problem is how to use the Uno API no mater programming language you 
prefer.


(...)

Hm. I have created a database to use instead of a spreadsheet. When I'm
trying to mail the document to myself as PDF, I can specify "Properties"
in the mailmerge wizard. There I could apparently add a text message so
that the PDF is sent as an attachment to it. I could use that to mail
the PDF documents to myself with the reference number in the text part
for easy further processing, or I might even be able to send them
without any further processing.

Unfortunately, LO crashes when I try to send the message:


,
| X Error: BadMatch (invalid parameter attributes) 8
|   Major opcode: 42 (X_SetInputFocus)
|   Resource id:  0x5001822
| #
| # A fatal error has been detected by the Java Runtime Environment:
| #
| #  SIGSEGV (0xb) at pc=0x7f2cabeb5751, pid=21389, tid=139829845436192
| #
| # JRE version: 6.0_18-b18
| # Java VM: OpenJDK 64-Bit Server VM (16.0-b13 mixed mode linux-amd64 )
| # Derivative: IcedTea6 1.8.7
| # Distribution: Debian GNU/Linux unstable (sid), package 6b18-1.8.7-4

Have you tried it with a stable  Version

| # Problematic frame:
| # C  [libuno_sal.so.3+0x43751]  rtl_uString_release+0x1
| #
| # An error report file with more information is saved as:
| # /home/lee/hs_err_pid21389.log
| #
| # If you would like to submit a bug report, please include
| # instructions how to reproduce the bug and visit:
| #   http://icedtea.classpath.org/bugzilla
| #
|
| [error occurred during error reporting , id 0xb]
`


This seems to be Java problem, and not a LO bug.
regards
Frieder


--
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread lee
"Twayne"  writes:

> In news:87iprv49kt@yun.yagibdah.de,
> lee  typed:
>> John B  writes:
>>
>> The mailmerge tool requires an address list, which is
>> something I don't have and don't want to create in this
>> case.
>
> Without a maling list "data file" you pretty much limit yourself out
> of a very easy process. Somehow you've not been clear with your
> message or you don't understand somethng IMO.

You're right in that I can't use the mailmerge tool without some sort of
list providing the data I need to insert into the document, since that's
the way the tool is supposed to work. If it would work, I could use it.

-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread lee
Frieder  writes:

> Am 25.06.2011 00:53, schrieb lee:
>
> Yes I also did it with the macro recorder, but I can translate it to
> better code if you want (the dispatcher is not reliable ).

Exporting to PDF has turned out to be unreliable in LO, too.

>> It strikes me odd that I shall have to learn another programming
>> language to do something this simple ...
> The Problem is how to use the Uno API no mater programming language
> you prefer.

True --- is there a good documentation about it?

>> Hm. I have created a database to use instead of a spreadsheet. When I'm
>> trying to mail the document to myself as PDF, I can specify "Properties"
>> in the mailmerge wizard. There I could apparently add a text message so
>> that the PDF is sent as an attachment to it. I could use that to mail
>> the PDF documents to myself with the reference number in the text part
>> for easy further processing, or I might even be able to send them
>> without any further processing.
>>
>> Unfortunately, LO crashes when I try to send the message:

> Have you tried it with a stable  Version

No, I only tried the version that is in Debian testing. Libreoffice is
not in Debian stable. LO 3.3.3 is in unstable. I could try to install
it, only it probably has so many dependencies that it isn't advisable.

>> | # Problematic frame:
>> | # C  [libuno_sal.so.3+0x43751]  rtl_uString_release+0x1
>> | #
>> | # An error report file with more information is saved as:
>> | # /home/lee/hs_err_pid21389.log
>> | #
>> | # If you would like to submit a bug report, please include
>> | # instructions how to reproduce the bug and visit:
>> | #   http://icedtea.classpath.org/bugzilla
>> | #
>> |
>> | [error occurred during error reporting , id 0xb]
>> `
>>
> This seems to be Java problem, and not a LO bug.

There seem to be two bugs, one with using the mailmerge tool and another
one with reporting the bug. Anyway, they shouldn't use java for LO.

It doesn't really matter what the problem is, it's just not working, and
one bug after another turns up. After having learned a little about LO,
it seems to be still in a beta stage, and I need something that does
work. It's sad that there has been only very little progress in the
reliability of WYSIWYG word processors over the last 15--20 years.

-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread John B

On 25/06/2011 14:07, lee wrote:

Frieder  writes:


Am 25.06.2011 00:53, schrieb lee:

Yes I also did it with the macro recorder, but I can translate it to
better code if you want (the dispatcher is not reliable ).

Exporting to PDF has turned out to be unreliable in LO, too.


It strikes me odd that I shall have to learn another programming
language to do something this simple ...

The Problem is how to use the Uno API no mater programming language
you prefer.

True --- is there a good documentation about it?


Hm. I have created a database to use instead of a spreadsheet. When I'm
trying to mail the document to myself as PDF, I can specify "Properties"
in the mailmerge wizard. There I could apparently add a text message so
that the PDF is sent as an attachment to it. I could use that to mail
the PDF documents to myself with the reference number in the text part
for easy further processing, or I might even be able to send them
without any further processing.

Unfortunately, LO crashes when I try to send the message:

Have you tried it with a stable  Version

No, I only tried the version that is in Debian testing. Libreoffice is
not in Debian stable. LO 3.3.3 is in unstable. I could try to install
it, only it probably has so many dependencies that it isn't advisable.


| # Problematic frame:
| # C  [libuno_sal.so.3+0x43751]  rtl_uString_release+0x1
| #
| # An error report file with more information is saved as:
| # /home/lee/hs_err_pid21389.log
| #
| # If you would like to submit a bug report, please include
| # instructions how to reproduce the bug and visit:
| #   http://icedtea.classpath.org/bugzilla
| #
|
| [error occurred during error reporting , id 0xb]
`


This seems to be Java problem, and not a LO bug.

There seem to be two bugs, one with using the mailmerge tool and another
one with reporting the bug. Anyway, they shouldn't use java for LO.

It doesn't really matter what the problem is, it's just not working, and
one bug after another turns up. After having learned a little about LO,
it seems to be still in a beta stage, and I need something that does
work. It's sad that there has been only very little progress in the
reliability of WYSIWYG word processors over the last 15--20 years.

---

I am with you on this (excluding Lotus Word Pro), frustration

I have tried the mailmerge facility in LO and I as yet cannot get 
anywhere with it.


Having got to "insert address block"  which on my system is greyed out.

I have made a small data base > Select Address List > create

Then entered some dummy names and addresses, then click ok and saved as 
a csv file


 then clicked on the file name, then OK on the window box (which took a 
few clicks to appear - minor bug)


Then nothing - the Finish button is still greyed out - Big Bug

regards

John B


--
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread Frieder

Am 25.06.2011 15:07, schrieb lee:

Frieder  writes:


Am 25.06.2011 00:53, schrieb lee:

Yes I also did it with the macro recorder, but I can translate it to
better code if you want (the dispatcher is not reliable ).

Exporting to PDF has turned out to be unreliable in LO, too.

do you men the Macro you produced with the macro recorder ?
The macro recorder uses the dispatcher, and the dispatcher is not 
reliable as I already mentioned.

It strikes me odd that I shall have to learn another programming
language to do something this simple ...

The Problem is how to use the Uno API no mater programming language
you prefer.

True --- is there a good documentation about it?

Yes there is:
http://wiki.services.openoffice.org/wiki/Category:Tutorial
and specially the export to pdf:
http://wiki.services.openoffice.org/wiki/API/Tutorials/PDF_export

Hm. I have created a database to use instead of a spreadsheet. When I'm
trying to mail the document to myself as PDF, I can specify "Properties"
in the mailmerge wizard. There I could apparently add a text message so
that the PDF is sent as an attachment to it. I could use that to mail
the PDF documents to myself with the reference number in the text part
for easy further processing, or I might even be able to send them
without any further processing.

Unfortunately, LO crashes when I try to send the message:

Have you tried it with a stable  Version

No, I only tried the version that is in Debian testing. Libreoffice is
not in Debian stable. LO 3.3.3 is in unstable. I could try to install
it, only it probably has so many dependencies that it isn't advisable.
maybe you should try another  distribution like Suse, Fedora or Ubuntu 
(but don't try the Unity desktop its terrible. Use the XFCE 
desktop(Xubuntu) instead, it is similar to Gnome2 but much lighter and 
faster)   .
The problem with Debian is, that the stable version is to old, and the 
testing and unstable is to unstable.

| # Problematic frame:
| # C  [libuno_sal.so.3+0x43751]  rtl_uString_release+0x1
| #
| # An error report file with more information is saved as:
| # /home/lee/hs_err_pid21389.log
| #
| # If you would like to submit a bug report, please include
| # instructions how to reproduce the bug and visit:
| #   http://icedtea.classpath.org/bugzilla
| #
|
| [error occurred during error reporting , id 0xb]
`


This seems to be Java problem, and not a LO bug.

There seem to be two bugs, one with using the mailmerge tool and another
one with reporting the bug. Anyway, they shouldn't use java for LO.
but there is still a lot of Java code in LO. They are working hard to 
translate it into C++ code, but it will take a while.

It doesn't really matter what the problem is, it's just not working, and
one bug after another turns up. After having learned a little about LO,
it seems to be still in a beta stage, and I need something that does
work. It's sad that there has been only very little progress in the
reliability of WYSIWYG word processors over the last 15--20 years.
The LO code contains about 600 lines of code. it is not easy to 
think of all the functions, if you ad some new code.

 So some bugs are unavoidable.

Regards
Frieder



--
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread lee
Frieder  writes:

> Am 25.06.2011 15:07, schrieb lee:
>> Frieder  writes:
>>
>>> Am 25.06.2011 00:53, schrieb lee:
>>>
>>> The Problem is how to use the Uno API no mater programming language
>>> you prefer.
>> True --- is there a good documentation about it?
> Yes there is:
> http://wiki.services.openoffice.org/wiki/Category:Tutorial
> and specially the export to pdf:
> http://wiki.services.openoffice.org/wiki/API/Tutorials/PDF_export

Ah, thanks :)

 Unfortunately, LO crashes when I try to send the message:
>>> Have you tried it with a stable  Version
>> No, I only tried the version that is in Debian testing. Libreoffice is
>> not in Debian stable. LO 3.3.3 is in unstable. I could try to install
>> it, only it probably has so many dependencies that it isn't advisable.
> maybe you should try another  distribution like Suse, Fedora or Ubuntu
> (but don't try the Unity desktop its terrible.

No way, I'm not going to dump my perfectly working system just to be
able to run a more recent version of some software. I could probably
download the latest sources and compile them myself, but I don't feel
inclined to go to much effort to get a broken word processing software
to work. I'd probably only find either the same bugs or new ones.

> The problem with Debian is, that the stable version is to old, and the
> testing and unstable is to unstable.

That's not true. Stable can be old, and as long as it does what you need
it to, it isn't too old. Testing isn't unstable at all. I haven't tried
unstable or experimental except for a few packages every now and then I
needed a more recent version of.

>> Anyway, they shouldn't use java for LO.
> but there is still a lot of Java code in LO. They are working hard to
> translate it into C++ code, but it will take a while.

It's good to hear that they are working on removing it :)

>> It doesn't really matter what the problem is, it's just not working, and
>> one bug after another turns up. After having learned a little about LO,
>> it seems to be still in a beta stage, and I need something that does
>> work. It's sad that there has been only very little progress in the
>> reliability of WYSIWYG word processors over the last 15--20 years.
> The LO code contains about 600 lines of code. it is not easy to
> think of all the functions, if you ad some new code.
>  So some bugs are unavoidable.

It comes down to that beyond a certain point, the effort that needs to
be put into making it easier to achieve a particular result exceeds the
effort that must be put into achieving the particular result. In this
case, unfortunately I've reached that point.

-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread lee
John B  writes:

> I have tried the mailmerge facility in LO and I as yet cannot get
> anywhere with it.

Hm, it's not too difficult to get to the point where you could finally
save, print or send your documents. Just make sure that there are no
unmatched fields. As someone described, you can even drag and drop
fields from a database into your document.

I could use mailmerge if it would reliably send the documents rather
than sometimes say "0 of 0 messages sent" despite there are two messages
to be sent --- and if the PDF created that way wasn't messed up. And it
would even be really useful if changing the "properties" when sending
documents as PDF would work rather than crash LO.

-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread Tom Davies
Hi :)

It might be a good time to file a bug-report about the pdf properties issue
http://wiki.documentfoundation.org/BugReport
Regards from
Tom :)




From: lee 
To: users@global.libreoffice.org
Sent: Sat, 25 June, 2011 20:32:18
Subject: Re: [libreoffice-users] Re: using fields in a text document

John B  writes:

> I have tried the mailmerge facility in LO and I as yet cannot get
> anywhere with it.

Hm, it's not too difficult to get to the point where you could finally
save, print or send your documents. Just make sure that there are no
unmatched fields. As someone described, you can even drag and drop
fields from a database into your document.

I could use mailmerge if it would reliably send the documents rather
than sometimes say "0 of 0 messages sent" despite there are two messages
to be sent --- and if the PDF created that way wasn't messed up. And it
would even be really useful if changing the "properties" when sending
documents as PDF would work rather than crash LO.
-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted


Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread Frieder

Am 25.06.2011 21:32, schrieb lee:
Hi Lee

John B  writes:


I have tried the mailmerge facility in LO and I as yet cannot get
anywhere with it.

Hm, it's not too difficult to get to the point where you could finally
save, print or send your documents. Just make sure that there are no
unmatched fields. As someone described, you can even drag and drop
fields from a database into your document.

I could use mailmerge if it would reliably send the documents rather
than sometimes say "0 of 0 messages sent" despite there are two messages
to be sent --- and if the PDF created that way wasn't messed up. And it
would even be really useful if changing the "properties" when sending
documents as PDF would work rather than crash LO.
If you are still interested in a reliable  macro that can export to PDF 
with a password I have  coded some lines for You: (StarBasic code)


sub export_pdf_with_password

odoc=ThisComponent.CurrentController.Frame
sURL = "file:///C:/Users/Nansen/Documents/RundschreibenTest0096.pdf" 
'variable to hold the Path


dim args1(5) as new com.sun.star.beans.PropertyValue
'args1(0).Name = "UseTaggedPDF"
'args1(0).Value= true

args1(0).Name = "ExportFormFields" 'just schow the contens of the Form.Filds
args1(0).Value= false
args1(1).Name = "Printing" ' you don't need that.
args1(1).Value= 2
args1(2).Name = "RestrictPermissions" 'If true, selects to restrict some 
permissions. The permissions can be changed only when the user enters 
the correct password.

args1(2).Value= true
args1(3).Name = "PermissionPassword"
args1(3).Value= "www2" 'coud be a variable
args1(4).Name = "EncryptFile" 'If true, selects to encrypt the PDF 
document with a password. The PDF file can be opened only when the user 
enters the correct password.

args1(4).Value= true
args1(5).Name = "DocumentOpenPassword"
args1(5).Value= "www" 'coud be a variable

'here you can enter some more options from the " 
http://wiki.services.openoffice.org/wiki/API/Tutorials/PDF_export " if 
you want


dim args2(2) as new com.sun.star.beans.PropertyValue

args2(0).Name = "FilterName"
args2(0).Value = "writer_pdf_Export"
args2(1).Name = "FilterData"
args2(1).Value = args1

thisComponent.storeToURL(sURL,args2())
end sub

I have done a complete solution for your hole problem (not totally 
complete  jett). I used a database (instead of a Calc file) .
I can send the solution to you  but I think you have to reconnect the 
Writer-document and the Database on your computer.


Regards Frieder


--
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: using fields in a text document

2011-06-25 Thread Tom Davies
Hi :)
I have been wondering about trying to run a more stable version of LO on 
Debian.  Can Debian run PPA repos from Ubuntu?  or is that a bit hit&miss due 
to 
differences within the Debian family?  Even if you are not able to get the 
3.3.3 
or 3.3.2 from the Debian repos the untweaked debs from the LO/TDF website might 
be an improvement on what you have now.  There are instructions on the wiki for 
installing more than 1 version of LO/OOo at a time so that you can test without 
throwing away anything that you have set-up so far.  I don't know if that is a 
good route tho?
Regards from
Tom :)

-- 
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted


Re: [libreoffice-users] Re: using fields in a text document

2011-06-26 Thread John B

On 25/06/2011 20:32, lee wrote:

John B  writes:


I have tried the mailmerge facility in LO and I as yet cannot get
anywhere with it.

Hm, it's not too difficult to get to the point where you could finally
save, print or send your documents. Just make sure that there are no
unmatched fields. As someone described, you can even drag and drop
fields from a database into your document.

I could use mailmerge if it would reliably send the documents rather
than sometimes say "0 of 0 messages sent" despite there are two messages
to be sent --- and if the PDF created that way wasn't messed up. And it
would even be really useful if changing the "properties" when sending
documents as PDF would work rather than crash LO.

I use mail merge all the time - it is quick and a joy, so - I thought 
that I would have a real go at getting LO mail merge to work this weekend.


Mail merge unfortunately  turns out to be unacceptably fragile

I finally gave up on LO 3.4 after a couple of hours (plus the hours 
before that) - it just does not work


I uninstalled 3.4 and installed 3.3.3 - This worked fine the first time 
(and never thereafter) to make a letter with the inbuilt standard 
contact fields (Title, First name etc) and made up 4 contact details


I noticed that the contact list is saved as a "tab" delineated 
spreadsheet in *.csv format.


One useful feature is that mail merge auto posts all the fields onto the 
letter for you, you can then move them (or delete) to a position of your 
choosing


You can even copy & paste fields in the letter so that the same data can 
appear as many times as you like on the document where you need them.


All things at this point are good, excluding the fact that there is no 
navigation tool bar, hence you cannot just skip to the 3rd address or 
the 1st or last address whilst looking at the letter. Other than that, 
it worked exactly as it should. So if its a small, one off and you have 
made no mistakes - brilliant.


closed all down it was at this point thereafter all things went wrong:-

1) On re-opening The database lost its connection to the letter and you 
had a chore to re-link the data fields in the *.csv file to those in the 
letter.


2) To add a "new contact" is too complex.

3) Merge, then adds all the fields again in bulk  to the letter for a 
2nd time, so you have to delete all the 1st batch


4) I thought maybe it would be better then, to add new contacts to the 
csv file in Calc

No problem there - up until you go back to Mail merge.
it corrupts the file in some way (or the 2 are incompatible). All the 
1st and last letters of any word are missing, eg, " company" becomes 
"ompan" and "zip" becomes "i", and it does the same to the data, then 
even when you merge you get nonsense data in the fields on the letter. 
Henceforth, totally useless.


I thought that maybe 3.3.3 is not as stable as it should be, so I 
installed 3.2 and it is still the same (missing letters etc)


Mail merge should be so simple, intuitive and above all reusable.

If anybody gets this to work in a stable and repeatable way, please let 
me know.


Also without a WYSIWYG navigation tool bar large databases would be out 
of the question - you also need navigation for printing, as in practice 
you want to print the 1st letter (to check), auto skip to the 2nd and if 
the 1st one is OK then you print "print the rest" or you can print the 
next one (one at a time) until you get it right. LO does not have this 
facility.


One strange feature I noticed is that on save / print it merges and 
generates  (in my case) all 4 letters, I assume then if you had a 
database of 1 names you would have a file with 1 letters (to big).



John B
Xp Pro sp3
LO 3.4, 3.3.3 & 3.2






























--
Unsubscribe instructions: E-mail to users+h...@global.libreoffice.org
In case of problems unsubscribing, write to postmas...@documentfoundation.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted