Skip to content
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

Not compatible with SmartFormat v3.0 #25

Closed
Scantheus opened this issue May 12, 2022 · 8 comments
Closed

Not compatible with SmartFormat v3.0 #25

Scantheus opened this issue May 12, 2022 · 8 comments

Comments

@Scantheus
Copy link

MailMergeLib v5.8
SmartFormat v3.0
Framework v4.8

MailMergeMessage mmm = new MailMergeMessage("Subject", "Message");

Gets exception "Method not found: 'Void.SmartFormat.SmartFormatter..ctor()'

Screen-2022-05-12_13-38-36

@axunonb
Copy link
Member

axunonb commented May 12, 2022

Correct, MailMergeLib v5.8 references SmartFormat v2.7.2

@Scantheus
Copy link
Author

Then shouldn't nuget dependency be set to SmartFormat.NET = 2.7.2 instead of >= 2.7.2?

@Scantheus
Copy link
Author

Ah, found the issue. Interesting. I think because my app is targeting NET 4.8, it doesn't take lowest version of dependencies since only NET v4.6.1 is in the MailMergeLib dependencies. I created a blank solution targeting Net 4.6.1 and correct dll versions are downloaded.

@axunonb
Copy link
Member

axunonb commented Jun 3, 2022

@Scantheus Today we released a new maintenance version of MailMergeLib (v5.8.2), which is available on NuGet. We included an explicit range of compatible versions for dependencies. Does this for for you, too?

@Scantheus
Copy link
Author

I don't see .NETFramework.Version=v4.8 in the Dependencies.

@Scantheus Scantheus reopened this Jun 7, 2022
@Scantheus
Copy link
Author

Tested (and it's a mess to revert back oof). You need NETFramework,Version=v4.8 with the same dependencies you have for v4.6.1. It appears if a framework is not explicitly defined, it will automatically take the latest version of the dependent packages. In this case, it pulls SmartFormat.NET v3.

@axunonb
Copy link
Member

axunonb commented Jun 7, 2022

Couldn't find anything about this behavior here and anywhere else. Thanks again for pointing this out.

@axunonb
Copy link
Member

axunonb commented Jun 29, 2023

Resolved with #38

@axunonb axunonb closed this as completed Jun 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants