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. Image for the cookie policy date
close icon

EntireColumn NumberFormat

Using 3.0.1.0 Are there any known issues assigning number formats to entire columns? I am using the following code but nothing seems to be assigned to the columns. If I assign a range the number format the values are formatted properly. Here''s my code: --- mySheet.Range[ "A1" ].EntireColumn.NumberFormat = "@"; mySheet.Range[ "B1:C1" ].EntireColumn.NumberFormat = "mm/dd/yyyy"; mySheet.Range[ "D1" ].EntireColumn.NumberFormat = "@"; mySheet.Range[ "E1:F1" ].EntireColumn.NumberFormat = "#,##0.00"; mySheet.Range[ "G1:H1" ].EntireColumn.NumberFormat = "@"; mySheet.Range[ "I1" ].EntireColumn.NumberFormat = "0.000"; mySheet.Range[ "J1" ].EntireColumn.NumberFormat = "mm/dd/yyyy"; mySheet.Range[ "K1:P1" ].EntireColumn.NumberFormat = "#,##0.00"; mySheet.Range[ "Q1" ].EntireColumn.NumberFormat = "@"; mySheet.Range[ "R1" ].EntireColumn.NumberFormat = "#"; Thanks for your help.

8 Replies

AD Administrator Syncfusion Team February 24, 2005 12:07 PM UTC

Hi Shannon, Sorry for the delay in getting back to you. Thanks for reporting this issue.I was able to see that the formatting was not applied when there was no data in the column. For example mySheet.Range[ "I1" ].EntireColumn.NumberFormat = "0.000"; This formating was applied when the cells in column I were not empty. I have contacted the development team regarding this issue and will update you when I hear back. Thanks, Stephen. >Using 3.0.1.0 > >Are there any known issues assigning number formats to entire columns? I am using the following code but nothing seems to be assigned to the columns. If I assign a range the number format the values are formatted properly. Here''s my code: > >--- > mySheet.Range[ "A1" ].EntireColumn.NumberFormat = "@"; > mySheet.Range[ "B1:C1" ].EntireColumn.NumberFormat = "mm/dd/yyyy"; > mySheet.Range[ "D1" ].EntireColumn.NumberFormat = "@"; > mySheet.Range[ "E1:F1" ].EntireColumn.NumberFormat = "#,##0.00"; > mySheet.Range[ "G1:H1" ].EntireColumn.NumberFormat = "@"; > mySheet.Range[ "I1" ].EntireColumn.NumberFormat = "0.000"; > mySheet.Range[ "J1" ].EntireColumn.NumberFormat = "mm/dd/yyyy"; > mySheet.Range[ "K1:P1" ].EntireColumn.NumberFormat = "#,##0.00"; > mySheet.Range[ "Q1" ].EntireColumn.NumberFormat = "@"; > mySheet.Range[ "R1" ].EntireColumn.NumberFormat = "#"; > > >Thanks for your help.


PH Patrick Hampton November 15, 2005 11:59 PM UTC

Stephen I am seeing a similar issue when I open an existing Excel workbook that has background color applied to an entire row or column. While looping through the cells on a worksheet, only cells that contain values have the correct background color stored in myRange.cellStyle.FillBackground. I have also checked in myWorksheet.Rows[x].EntireRow.cellStyle.FillBackground and the desired background color is not stored there either. Assuming I am looking in the correct place, are these two issues related, and if so has there been any progress on a solution? Thanks Patrick >Hi Shannon, > >Sorry for the delay in getting back to you. > >Thanks for reporting this issue.I was able to see that the formatting was not applied when there was no data in the column. For example > mySheet.Range[ "I1" ].EntireColumn.NumberFormat = "0.000"; > >This formating was applied when the cells in column I were not empty. I have contacted the development team regarding this issue and will update you when I hear back. > >Thanks, > >Stephen. > >>Using 3.0.1.0 >> >>Are there any known issues assigning number formats to entire columns? I am using the following code but nothing seems to be assigned to the columns. If I assign a range the number format the values are formatted properly. Here''s my code: >> >>--- >> mySheet.Range[ "A1" ].EntireColumn.NumberFormat = "@"; >> mySheet.Range[ "B1:C1" ].EntireColumn.NumberFormat = "mm/dd/yyyy"; >> mySheet.Range[ "D1" ].EntireColumn.NumberFormat = "@"; >> mySheet.Range[ "E1:F1" ].EntireColumn.NumberFormat = "#,##0.00"; >> mySheet.Range[ "G1:H1" ].EntireColumn.NumberFormat = "@"; >> mySheet.Range[ "I1" ].EntireColumn.NumberFormat = "0.000"; >> mySheet.Range[ "J1" ].EntireColumn.NumberFormat = "mm/dd/yyyy"; >> mySheet.Range[ "K1:P1" ].EntireColumn.NumberFormat = "#,##0.00"; >> mySheet.Range[ "Q1" ].EntireColumn.NumberFormat = "@"; >> mySheet.Range[ "R1" ].EntireColumn.NumberFormat = "#"; >> >> >>Thanks for your help.


AD Administrator Syncfusion Team November 16, 2005 07:08 AM UTC

Hi Patrick, Regarding the First issue (Number Format), it has been addressed again to the developement team with priority high. It will be resolved soon. Regarding the Second issue (Background styles), there has been added a property IWorksheet.SetDefaultColumnStyle and IWorksheet.SetDefaultRowStyle for default styles in the latest internal version. It will be available in the next release. The next release is on November 21st. Sorry for the Inconvenience. Thanks for your interest with Syncfusion products. Best Regards, Seetha >Stephen > >I am seeing a similar issue when I open an existing Excel workbook that has background color applied to an entire row or column. While looping through the cells on a worksheet, only cells that contain values have the correct background color stored in myRange.cellStyle.FillBackground. I have also checked in myWorksheet.Rows[x].EntireRow.cellStyle.FillBackground and the desired background color is not stored there either. > >Assuming I am looking in the correct place, are these two issues related, and if so has there been any progress on a solution? > >Thanks >Patrick > >>Hi Shannon, >> >>Sorry for the delay in getting back to you. >> >>Thanks for reporting this issue.I was able to see that the formatting was not applied when there was no data in the column. For example >> mySheet.Range[ "I1" ].EntireColumn.NumberFormat = "0.000"; >> >>This formating was applied when the cells in column I were not empty. I have contacted the development team regarding this issue and will update you when I hear back. >> >>Thanks, >> >>Stephen. >> >>>Using 3.0.1.0 >>> >>>Are there any known issues assigning number formats to entire columns? I am using the following code but nothing seems to be assigned to the columns. If I assign a range the number format the values are formatted properly. Here''s my code: >>> >>>--- >>> mySheet.Range[ "A1" ].EntireColumn.NumberFormat = "@"; >>> mySheet.Range[ "B1:C1" ].EntireColumn.NumberFormat = "mm/dd/yyyy"; >>> mySheet.Range[ "D1" ].EntireColumn.NumberFormat = "@"; >>> mySheet.Range[ "E1:F1" ].EntireColumn.NumberFormat = "#,##0.00"; >>> mySheet.Range[ "G1:H1" ].EntireColumn.NumberFormat = "@"; >>> mySheet.Range[ "I1" ].EntireColumn.NumberFormat = "0.000"; >>> mySheet.Range[ "J1" ].EntireColumn.NumberFormat = "mm/dd/yyyy"; >>> mySheet.Range[ "K1:P1" ].EntireColumn.NumberFormat = "#,##0.00"; >>> mySheet.Range[ "Q1" ].EntireColumn.NumberFormat = "@"; >>> mySheet.Range[ "R1" ].EntireColumn.NumberFormat = "#"; >>> >>> >>>Thanks for your help.


PH Patrick Hampton November 16, 2005 05:51 PM UTC

Seetha Thanks for the quick response, but I''m not sure that IWorksheet.SetDefaultColumnStyle/IWorksheet.SetDefaultRowStyle would apply in my situation. I have an Excel Spreadsheet that was built in Excel with the following properties. Rows 1-4 have the default cell properties on the entire row, Rows 5-8 have a different background color applied to the entire row, Columns C-E have values set in the cells. I read in the worksheet using IApplication.Workbooks.Opan() and get the list of cells using IApplication.ActiveWorkbook.ActiveSheet.Cells which returns a list of cells representing the Range A1:F9 (so far so good). Now while looping through the list of cells I find that only C5:E8 have the background color that was applied to the rows, while A5:B8 have the default background color. I have also checked IRange.EntireRow and the background color appears to be set to the default for A5:B8. Is there somewhere else that I can look in ExcelRW to get row level formatting information on a worksheet. >Hi Patrick, > >Regarding the First issue (Number Format), it has been addressed again to the developement team with priority high. It will be resolved soon. >Regarding the Second issue (Background styles), there has been added a property IWorksheet.SetDefaultColumnStyle and IWorksheet.SetDefaultRowStyle for default styles in the latest internal version. It will be available in the next release. The next release is on November 21st. > >Sorry for the Inconvenience. > >Thanks for your interest with Syncfusion products. > >Best Regards, >Seetha >


AD Administrator Syncfusion Team November 17, 2005 04:53 AM UTC

Hi Patrick, Can you please send me the sample file, so that i could test with the latest build and tell you the solution for this issue. Sorry for the Inconvenience. Best Regards, Seetha >Seetha > >Thanks for the quick response, but I''m not sure that IWorksheet.SetDefaultColumnStyle/IWorksheet.SetDefaultRowStyle would apply in my situation. I have an Excel Spreadsheet that was built in Excel with the following properties. >Rows 1-4 have the default cell properties on the entire row, >Rows 5-8 have a different background color applied to the entire row, >Columns C-E have values set in the cells. > >I read in the worksheet using IApplication.Workbooks.Opan() and get the list of cells using IApplication.ActiveWorkbook.ActiveSheet.Cells >which returns a list of cells representing the Range A1:F9 (so far so good). Now while looping through the list of cells I find that only C5:E8 have the background color that was applied to the rows, while A5:B8 have the default background color. I have also checked IRange.EntireRow and the background color appears to be set to the default for A5:B8. Is there somewhere else that I can look in ExcelRW to get row level formatting information on a worksheet. > >>Hi Patrick, >> >>Regarding the First issue (Number Format), it has been addressed again to the developement team with priority high. It will be resolved soon. >>Regarding the Second issue (Background styles), there has been added a property IWorksheet.SetDefaultColumnStyle and IWorksheet.SetDefaultRowStyle for default styles in the latest internal version. It will be available in the next release. The next release is on November 21st. >> >>Sorry for the Inconvenience. >> >>Thanks for your interest with Syncfusion products. >> >>Best Regards, >>Seetha >>


PH Patrick Hampton November 17, 2005 04:36 PM UTC

Seetha Attached is the .xls file I am using for testing. Thanks Patrick >Hi Patrick, > >Can you please send me the sample file, so that i could test with the latest build and tell you the solution for this issue. > >Sorry for the Inconvenience. > >Best Regards, >Seetha > > > >>Seetha >> >>Thanks for the quick response, but I''m not sure that IWorksheet.SetDefaultColumnStyle/IWorksheet.SetDefaultRowStyle would apply in my situation. I have an Excel Spreadsheet that was built in Excel with the following properties. >>Rows 1-4 have the default cell properties on the entire row, >>Rows 5-8 have a different background color applied to the entire row, >>Columns C-E have values set in the cells. >> >>I read in the worksheet using IApplication.Workbooks.Opan() and get the list of cells using IApplication.ActiveWorkbook.ActiveSheet.Cells >>which returns a list of cells representing the Range A1:F9 (so far so good). Now while looping through the list of cells I find that only C5:E8 have the background color that was applied to the rows, while A5:B8 have the default background color. I have also checked IRange.EntireRow and the background color appears to be set to the default for A5:B8. Is there somewhere else that I can look in ExcelRW to get row level formatting information on a worksheet. >> >>>Hi Patrick, >>> >>>Regarding the First issue (Number Format), it has been addressed again to the developement team with priority high. It will be resolved soon. >>>Regarding the Second issue (Background styles), there has been added a property IWorksheet.SetDefaultColumnStyle and IWorksheet.SetDefaultRowStyle for default styles in the latest internal version. It will be available in the next release. The next release is on November 21st. >>> >>>Sorry for the Inconvenience. >>> >>>Thanks for your interest with Syncfusion products. >>> >>>Best Regards, >>>Seetha >>>

test10.zip


PH Patrick Hampton November 17, 2005 04:49 PM UTC

I need to make a correction as well. The FillBackground color on the EntireRow member is being set to Black as opposed to BlackCustom(the default). Patrick >Seetha > >Attached is the .xls file I am using for testing. > >Thanks >Patrick > >>Hi Patrick, >> >>Can you please send me the sample file, so that i could test with the latest build and tell you the solution for this issue. >> >>Sorry for the Inconvenience. >> >>Best Regards, >>Seetha >> >> >> >>>Seetha >>> >>>Thanks for the quick response, but I''m not sure that IWorksheet.SetDefaultColumnStyle/IWorksheet.SetDefaultRowStyle would apply in my situation. I have an Excel Spreadsheet that was built in Excel with the following properties. >>>Rows 1-4 have the default cell properties on the entire row, >>>Rows 5-8 have a different background color applied to the entire row, >>>Columns C-E have values set in the cells. >>> >>>I read in the worksheet using IApplication.Workbooks.Opan() and get the list of cells using IApplication.ActiveWorkbook.ActiveSheet.Cells >>>which returns a list of cells representing the Range A1:F9 (so far so good). Now while looping through the list of cells I find that only C5:E8 have the background color that was applied to the rows, while A5:B8 have the default background color. I have also checked IRange.EntireRow and the background color appears to be set to the default for A5:B8. Is there somewhere else that I can look in ExcelRW to get row level formatting information on a worksheet. >>> >>>>Hi Patrick, >>>> >>>>Regarding the First issue (Number Format), it has been addressed again to the developement team with priority high. It will be resolved soon. >>>>Regarding the Second issue (Background styles), there has been added a property IWorksheet.SetDefaultColumnStyle and IWorksheet.SetDefaultRowStyle for default styles in the latest internal version. It will be available in the next release. The next release is on November 21st. >>>> >>>>Sorry for the Inconvenience. >>>> >>>>Thanks for your interest with Syncfusion products. >>>> >>>>Best Regards, >>>>Seetha >>>>

test10.zip


AD Administrator Syncfusion Team November 18, 2005 05:01 AM UTC

Hi Patrick, Thanks for sending me the Sample file. I tested your .xls file and was able to see the problem with the background colors and have filed a bug report with the development team. Bug Id:#1067. It will be resolved soon before the next release. Sorry for the Inconvenience. Thanks for your interest with Syncfusion Products. Best Regards, Seetha >I need to make a correction as well. The FillBackground color on the EntireRow member is being set to Black as opposed to BlackCustom(the default). > >Patrick > >>Seetha >> >>Attached is the .xls file I am using for testing. >> >>Thanks >>Patrick >> >>>Hi Patrick, >>> >>>Can you please send me the sample file, so that i could test with the latest build and tell you the solution for this issue. >>> >>>Sorry for the Inconvenience. >>> >>>Best Regards, >>>Seetha >>> >>> >>> >>>>Seetha >>>> >>>>Thanks for the quick response, but I''m not sure that IWorksheet.SetDefaultColumnStyle/IWorksheet.SetDefaultRowStyle would apply in my situation. I have an Excel Spreadsheet that was built in Excel with the following properties. >>>>Rows 1-4 have the default cell properties on the entire row, >>>>Rows 5-8 have a different background color applied to the entire row, >>>>Columns C-E have values set in the cells. >>>> >>>>I read in the worksheet using IApplication.Workbooks.Opan() and get the list of cells using IApplication.ActiveWorkbook.ActiveSheet.Cells >>>>which returns a list of cells representing the Range A1:F9 (so far so good). Now while looping through the list of cells I find that only C5:E8 have the background color that was applied to the rows, while A5:B8 have the default background color. I have also checked IRange.EntireRow and the background color appears to be set to the default for A5:B8. Is there somewhere else that I can look in ExcelRW to get row level formatting information on a worksheet. >>>> >>>>>Hi Patrick, >>>>> >>>>>Regarding the First issue (Number Format), it has been addressed again to the developement team with priority high. It will be resolved soon. >>>>>Regarding the Second issue (Background styles), there has been added a property IWorksheet.SetDefaultColumnStyle and IWorksheet.SetDefaultRowStyle for default styles in the latest internal version. It will be available in the next release. The next release is on November 21st. >>>>> >>>>>Sorry for the Inconvenience. >>>>> >>>>>Thanks for your interest with Syncfusion products. >>>>> >>>>>Best Regards, >>>>>Seetha >>>>>

test10.zip

Loader.
Live Chat Icon For mobile
Up arrow icon