[Solved] Inserting header
-
- Posts: 12
- Joined: Tue Jun 15, 2010 1:53 pm
[Solved] Inserting header
Hi,
I want to insert a header using data from a .ott(open document Text Template) file.
I am not getting a way to do this.
My .ott file contains tables too.
So please guide me the way of doing this.
I want to insert a header using data from a .ott(open document Text Template) file.
I am not getting a way to do this.
My .ott file contains tables too.
So please guide me the way of doing this.
Last edited by sid_openoffice_1 on Thu Jul 15, 2010 3:01 pm, edited 1 time in total.
Windows OpenOffice 3.2
- Hagar Delest
- Moderator
- Posts: 32658
- Joined: Sun Oct 07, 2007 9:07 pm
- Location: France
Re: inserting header
I fear we need some additional information!
What kind of data do you want to get? A template is used to create a document already pre-formatted so once the template is ready, the documents based on it should be fine from their creation.
If your template contains tables, then your documents get them too.
Can you upload it and tell us what's wrong (see: How to attach a document here)?
What kind of data do you want to get? A template is used to create a document already pre-formatted so once the template is ready, the documents based on it should be fine from their creation.
If your template contains tables, then your documents get them too.
Can you upload it and tell us what's wrong (see: How to attach a document here)?
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
-
- Posts: 12
- Joined: Tue Jun 15, 2010 1:53 pm
Re: inserting header
Actually i want to load that document in the header.
And I am not geting the way to do this.
And I am not geting the way to do this.
Windows OpenOffice 3.2
Re: Inserting header
You're going to have to give us more to work with!
Please tell us in more detail what you want to achieve, and what you have tried.
Please tell us in more detail what you want to achieve, and what you have tried.
Ubuntu 14.10 Utopic Unicorn, LibreOffice Version: 4.3.3.2
Gurkha Welfare Trust
Gurkha Welfare Trust
Re: inserting header
That does not clarify anything. To provide any help, we need the following:sid_openoffice_1 wrote:Actually i want to load that document in the header.
And I am not geting the way to do this.
The document(s) you are working with (remove any sensitive data first). See link above for help with attaching files.
Tell us what you want to achieve.
Preferably, tell us what you have done (if you have gotten anywhere at all with this), and what result you got.
Apache OO 4.1.12 and LibreOffice 7.5, mostly on Ms Windows 10
-
- Posts: 12
- Joined: Tue Jun 15, 2010 1:53 pm
Re: inserting header
Hi,
Please find the 2 attachment with this in which one is my code file and the other is the .ott file.
I want to insert the "TimeOffRequestForm.ott" file into the header.Is there a possibility of doing this?If yes please guide me how to do it.
Regards
Siddharth
Genpact
India
Please find the 2 attachment with this in which one is my code file and the other is the .ott file.
I want to insert the "TimeOffRequestForm.ott" file into the header.Is there a possibility of doing this?If yes please guide me how to do it.
Regards
Siddharth
Genpact
India
- Attachments
-
- TimeOffRequestForm.ott
- this is the template file whch is to be used
- (15.6 KiB) Downloaded 346 times
-
- header inserting file.odt
- this is my code file in c#.I want to insert the "TimeOffRequestForm.ott" file into the header.Is there a possibility of doing this?If yes please guide me how to do it.
- (17.88 KiB) Downloaded 333 times
Windows OpenOffice 3.2
Re: Inserting header
In my opinion that .ott file not contain any header. It might be called "Cover Page"
Why not you copy-paste your document into .ott file? Just type Ctrl-Enter in .ott file, and at beginning of second page paste the all text from .odt file, and on .ott file: save as...
Why not you copy-paste your document into .ott file? Just type Ctrl-Enter in .ott file, and at beginning of second page paste the all text from .odt file, and on .ott file: save as...
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
-
- Posts: 12
- Joined: Tue Jun 15, 2010 1:53 pm
Re: Inserting header
Hi,
Thanks for the reply bt i have to do that programmatically and in this i have to insert that .ott file into the header.
Regards.
Thanks for the reply bt i have to do that programmatically and in this i have to insert that .ott file into the header.
Regards.
Windows OpenOffice 3.2
Re: Inserting header
So long as your TimeOffRequest form is visible, does it matter if it is in the header, or on the first page?
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
Re: Inserting header
Hi, sid_openoffice_1
An appropriate solution would be for you the following proposal?
Idea:
Automated autotext function
description:
First, highlight the text in the template file.
Pick up one into the "Autotext" function (Edit ->Autotext -> ...)
(I picked up named as "TORForm" with short name "T" in my OpenOffice.
The recorded macro will insert the into the (new) first page of the document.
On first page the macro will insert the autotext item named "T".
(The recorded macro stored in the BASIC repository of this document. You need to store into OpenOffice BASIC repository. Associate the macro to a new menu or the toolbar is a new element, then it will be always available.
(You can develop the macro. For example, to set the new first page to "First Page" pagestyle)
An appropriate solution would be for you the following proposal?
Idea:
Automated autotext function
description:
First, highlight the text in the template file.
Pick up one into the "Autotext" function (Edit ->Autotext -> ...)
(I picked up named as "TORForm" with short name "T" in my OpenOffice.
The recorded macro will insert the into the (new) first page of the document.
On first page the macro will insert the autotext item named "T".
(The recorded macro stored in the BASIC repository of this document. You need to store into OpenOffice BASIC repository. Associate the macro to a new menu or the toolbar is a new element, then it will be always available.
(You can develop the macro. For example, to set the new first page to "First Page" pagestyle)
Code: Select all
REM ***** BASIC *****
Option Explicit
sub InsertFirstPage
rem ----------------------------------------------------------------------
rem define variables
dim document as object
dim dispatcher as object
rem ----------------------------------------------------------------------
rem get access to the document
document = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
rem ----------------------------------------------------------------------
dispatcher.executeDispatch(document, ".uno:GoToStartOfDoc", "", 0, Array())
rem ----------------------------------------------------------------------
dispatcher.executeDispatch(document, ".uno:InsertPagebreak", "", 0, Array())
rem ----------------------------------------------------------------------
dispatcher.executeDispatch(document, ".uno:GoToStartOfDoc", "", 0, Array())
rem ----------------------------------------------------------------------
dim args6(0) as new com.sun.star.beans.PropertyValue
args6(0).Name = "Group"
args6(0).Value = "mytexts*1"
dispatcher.executeDispatch(document, ".uno:SetActGlossaryGroup", "", 0, args6())
rem ----------------------------------------------------------------------
dim args7(1) as new com.sun.star.beans.PropertyValue
args7(0).Name = "Group"
args7(0).Value = "mytexts*1"
args7(1).Name = "ShortName"
args7(1).Value = "T"
dispatcher.executeDispatch(document, ".uno:InsertGlossary", "", 0, args7())
end sub
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.