We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Problem with AutoFit

Thread ID:

Created:

Updated:

Platform:

Replies:

63522 Jul 4,2007 10:41 PM UTC Jul 10,2007 11:22 AM UTC WinForms 6
loading
Tags: XlsIO
theEvil
Asked On July 4, 2007 10:41 PM UTC

Dear Sir,

I have some trouble with the AutoFit() method.
I create with C# a report in Excel but some column look like ######.
So I tried to use AutoFit command (like i'm using with the same report but throught COM) but the column continue to appear like this #####.
I have tried AutoFitColumn, AutoFitRow, or with sheet.AutoFitColumn(index) but nothing to do.

It is ok with ShrinkToFit but the caracter become too small and I can't leave it so.
Can you explain me what I have to do ?
Why by calling AutoFit via Excel COM it's all ok and with your assembly not ?

What can I do ?
Thanks a lot.

Melba Winshia [Syncfusion]
Replied On July 5, 2007 07:22 AM UTC

Hi,

Thank you for your interest in Essential XlsIO.

I tried to reproduce the issue using this sample.

http://websamples.syncfusion.com/samples/XlsIO.Windows/F63522/main.htm

But I was not able to reproduce the issue. Could you please try running the above sample and let us know if the problem still exists? If not could you please modify this sample so that I can reproduce the issue? This would help me in analyzing this issue further.

Thanks,
Melba

theEvil
Replied On July 5, 2007 04:25 PM UTC

I can't solve the problem.
I use AutoFit like you suggest.

The column has a style like this :

stileValuta.NumberFormat = "€ #,##0.00";

I even tried

stileValuta.NumberFormat = "€ #.##";

But nothing to do.
I write in bold,but I really need to write in bold.
What can I do ?

thanks

>Hi,

Thank you for your interest in Essential XlsIO.

I tried to reproduce the issue using this sample.

http://websamples.syncfusion.com/samples/XlsIO.Windows/F63522/main.htm

But I was not able to reproduce the issue. Could you please try running the above sample and let us know if the problem still exists? If not could you please modify this sample so that I can reproduce the issue? This would help me in analyzing this issue further.

Thanks,
Melba

theEvil
Replied On July 5, 2007 09:16 PM UTC

I have tried and tried again, in every possible way with AutoFitColumn,AutoFitRow from the range and from the sheet,after and before writing.

But nothing, nothing to do.
Can you explain me why ?
I really can't understand.
It works for some cells and not for other, but all the cell are created from the same function dynamically...it's impossible !

Thanks for your help.

Melba Winshia [Syncfusion]
Replied On July 6, 2007 10:23 AM UTC

Hi,

I am afraid that I was not able to reproduce the issue. Please refer to the following steps that I tried to reproduce it.

1. Created a style with NumberFormat "€ #,##0.00" and bold in a column
2. Apply AutofitColumns

Also I have created a simple sample to test this issue and it is available in the following link.

http://websamples.syncfusion.com/samples/XlsIO.Windows/F63522_1/main.htm

Please have a look at the above sample and if still the issue exists, could you please try reproducing it in the above sample or send us the reproducing steps so that we could sort out the cause of the issue and provide you a solution?

Regards,
Melba



theEvil
Replied On July 9, 2007 08:53 PM UTC

I've discovered that the problem happens when I define a style for the column.
In fact if I comment the code of the style the autofit immediately works fine.

What I have to do,to use the autofit togheter with the style ??

Thanks a lot.

Melba Winshia [Syncfusion]
Replied On July 10, 2007 11:22 AM UTC

Hi,

I am afraid that I was not able to reproduce the issue. Please refer to the following steps that I tried to reproduce it.

1. Define a style for the column
2. Apply AutofitColumns

Also I have created a simple sample to test this issue and it is available in the following link.

http://websamples.syncfusion.com/samples/XlsIO.Windows/F63522_2/main.htm

Please have a look at the above sample and if still the issue exists, could you please try reproducing it in the above sample or send us the reproducing steps so that we could sort out the cause of the issue and provide you a solution?

Regards,
Melba

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;