-
Notifications
You must be signed in to change notification settings - Fork 119
Upgrade to ClosedXML 0.100.3 #305
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
using System.Collections.Generic; | ||
using System.Text; | ||
|
||
namespace ClosedXML.Report.Utils; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feature 'file-scoped namespaces' is not available. Please use language version 10.0 or greater.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Current version is 7
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using latest for LangVersion should use the highest compatible C# for the targeted framework, no need to set to an explicit version number.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One of the supported frameworks is net462 which doesn't support c# 11. Change language version to the Latest
and try to compile.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have tried with latest, and it builds, even on net462: of course using language features not supported by net462 is gonna fail whatever the language version specified, so I would try to keep it as wide as possible by using latest.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was wrong. If I set the Latest version is OK, but if I set the version is 11 I get the compile error Invalid option '11' for /langversion. Use '/langversion:?' to list supported values.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
csc /langversion:? by me is listing 11 as the latest (and default version, so I think now can be omitted to get the latest).
csc /version gives 4.5.0-6.23128.14 (651d32d8)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I don't have .net 4.62 on my development machine.
Please wrap IXLCellExtensions class into namespace ClosedXML.Report.Utils.
@@ -64,6 +66,27 @@ public IXLCell WriteValue(object value, IXLCell settingCell) | |||
return xlCell; | |||
} | |||
|
|||
public IXLCell WriteCellValue(XLCellValue value, IXLCell settingCell) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Method 'WriteCellValue' return value is never used.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, 'WriteCellValue' return value is never used now. It's method overloading as WriteValue(object value, IXLCell settingCell).
ClosedXML.Report/Excel/Subtotal.cs
Outdated
@@ -237,7 +237,7 @@ private void MoveSummary(MoveData moveData) | |||
return; | |||
|
|||
trgtRng.Clear(); | |||
fcell.Value = srcRng; | |||
fcell.CopyFrom(srcRng); //fcell.Value = srcRng; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove all your commented text. We have git )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed my comments and then pushed it again.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I cloned the branch and got the next error:
ClosedXML.Report.Tests.csproj: [NU1605] Warning As Error: Detected package downgrade: System.Linq.Dynamic.Core from 1.3.1 to 1.2.20. Reference the package directly from the project to select a different version.
ClosedXML.Report.Tests -> ClosedXML.Report -> System.Linq.Dynamic.Core (>= 1.3.1)
ClosedXML.Report.Tests -> System.Linq.Dynamic.Core (>= 1.2.20)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Closed via #307. @mymintin thank you for the try! Unfortunately, this particular upgrade turned out to be way harder than a usual "bump all dependencies up". |
Upgrade to ClosedXML v 0.100.3