Bonsoir Mélanie
Tu peux essayer
option explicit
Sub AlignementDansCelluleA1
Dim oDocument As Object,oCell As Object
oDocument=ThisComponent.Sheets.getByName("Feuille1")
oCell=oDocument.getCellByPosition(0,0)'cellule A1
oCell.VertJustify = com.sun.star.table.CellVertJustify.TOP
'pour info
'oCell.VertJustify = com.sun.star.table.CellVertJustify.BOTTOM
'oCell.VertJustify = com.sun.star.table.CellVertJustify.CENTER
'oCell.HoriJustify = com.sun.star.table.CellHoriJustify.LEFT
'oCell.HoriJustify = com.sun.star.table.CellHoriJustify.RIGHT
'oCell.HoriJustify = com.sun.star.table.CellHoriJustify.CENTER
End Sub
Bonne soirée
michel
-----Message d'origine-----
De : mpru...@elv.enic.fr [mailto:mpru...@elv.enic.fr]
Envoyé : jeudi 1 juillet 2004 12:37
À : pr...@fr.openoffice.org
Objet : [prog] alignement vertical en haut dans un tableau
Bonjour,
Comment puis-je dans mon tableau faire en sorte que les cellules ont un
alignement vertical en haut. Cette propriété est présente dans la boite
de dialogue "format d'un tableau" mais lors de l'enregistrement de ma
macro, cette propriété n'est pas enregistrée. Comment puis-je coder
cette propriété??
Merci,
Cordialement,
Mélanie Prudhon.