Defualt Direction?


#1

hi

i need to change the Defualt Direction to 'right-to-left' using Aspose.Excel but i don't now the attribute that control this option.

please advice.

thanks in advance


#2

Aspose.Excel is changed to Aspose.Cells now. Please try following piece of code:

Style style = workbook.DefaultStyle;

style.TextDirection = TextDirectionType.RightToLeft;


#3

this well help in the cell level

BUT I NEED THIS ON THE SHEET LEVEL


#4

Please try this piece of code:

Workbook workbook = new Workbook();

Style style = workbook.DefaultStyle;

style.TextDirection = TextDirectionType.RightToLeft;

workbook.DefaultStyle = style;

workbook.Save("d:\\test\\abc.xls");

You can see that all cells in the workbook is right-to-left by default.


#5

Crying [:'(]

Again that help me to set the direction of the text.

what aim realy want is to set the direction of the sheet to right-to-left

i want the columns to start from the right

you can do it in Excel 2003 by

Tools > Options > then go to the "International" Tab

for the Defualt Direction check Rght-to-left radio button. then reopen the Excel you will see what i want my sheet to look like using aspose.cell

thanks


#6

Thanks for your information. Now I am clear about your need.

This feature is not supported yet. I will make it right now. You will get it in about 1-2 days.


#7

Please try this piece of code with the attached version:

Workbook book = new Workbook();


Worksheet sheet = book.Worksheets[0];

sheet.DisplayRightToLeft = true;

book.Save("d:\\test\\abc.xls");