How to align text in center using vb.net

Creating a macro - Writing a Script - Using the API

How to align text in center using vb.net

Postby npandit » Fri Nov 29, 2019 7:34 am

Hello
I have merged the following cells using the code:
ocell98=oSheet.getCellrangeByname("A3:B6")
ocell98.merge(true)
However i want to align the text of ocell98 in center
Can anyone suggest how to set alignment of text ?
Open Office 4.1.7
npandit
 
Posts: 13
Joined: Mon Nov 11, 2019 10:09 am

Re: How to align text in center using vb.net

Postby Zizi64 » Fri Nov 29, 2019 7:54 am

Can anyone suggest how to set alignment of text ?


Just apply your own cell style (manually or by your code). The direct formatting method is not too efficient.
Tibor Kovacs, Hungary; LO6.1.6, 6.2.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-6.4.0; AOO4.1.6
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.
User avatar
Zizi64
Volunteer
 
Posts: 8777
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary


Return to Macros and UNO API

Who is online

Users browsing this forum: Google [Bot] and 8 guests