Re: Functies voor toegang tot documenteigenschappen in Calc

Cor Nouws <[email protected]>
Newsgroups gmane.comp.openoffice.users.dutch
Message-ID <[email protected]>
Dag Ferry,

Ferry Toth wrote (08-05-10 23:48)
> In Writer kun je een aantal document eigenschappen (filenaam, Titel,
> datum opgeslagen) als veld in het document opnemen.
> 
> In Calc wil ik dat ook, in een cel. Ik zoek dus functies om dat te
> kunnen doen.
> 
> Het enige dat ik kan vinden zijn de knoppen om deze gegevens in de
> footer te zetten.
> 
> Maar dat is precies wat ik wil voorkomen. De opmaak mogelijkheden van de
> footer zijn te beperkt, en dus wil ik deze informatie in cellen zetten.

De eigenschappen zijn in het document wel bekend ja, maar er is geen 
ingang in de interface om ze te plaatsen.
Je kunt een functie toevoegen in Basic, in de Standard bibliotheek, die 
je wel de mogelijkheid geeft.
Bijvoorbeeld:

Function MyDocInfo(sInput as string) as string
	Dim s$
	Select Case UCASE(sInput)
	Case "AUTHOR"
		s = ThisComponent.Documentinfo.Author
	Case "PRINTDATE"
		s = ThisComponent.Documentinfo.PrintDate
	Case Else
		s = " ..  onbekend .. "
	End Select

	MyDocInfo = s
End Function

ThisComponent.Documentinfo heeft natuurlijk nog meer eigenschappen.

Is dat een optie voor je?
vr. groet,
Cor

-- 
  >> Your office 2010 software: the new OpenOffice.org <<

Cor Nouws
   - ideas/remarks for the community council?
   - http://wiki.services.openoffice.org/wiki/Community_Council
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.