FluentEmail icon indicating copy to clipboard operation
FluentEmail copied to clipboard

RazorRenderer cannot work well with .netfx 4.7.1

Open cyciopes opened this issue 6 years ago • 2 comments

Hi, I was testing FluentEmail with RazorRender and .netfx 4.7.1, but is always reported exception. Am I missing something to get it worked well with .netfx 4.7.1? My FluentEmail version was 2.7.0. Btw, I also tried it with .net core 2.2, the RazorRenderer worked well with it. Thanks in advance.

image

using FluentEmail.Core;
using FluentEmail.Smtp;
using FluentEmail.Razor;
using RazorLight.Razor;
using Microsoft.Extensions.DependencyInjection;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Net.Mail;
using System.Text;
using System.Threading.Tasks;
using Xunit;

namespace GeneralTest
{
    public class FluntEmailTest
    {
        public FluntEmailTest()
        {
            Email.DefaultRenderer = new RazorRenderer();
        }

        [Fact]
        public void Test1()
        {
        }
    }
}

cyciopes avatar Oct 24 '19 07:10 cyciopes

Fixed by #186

bjcull avatar Jan 04 '20 10:01 bjcull

This is still occuring in FluentEmail 3.0.0 with RazorLight 2.0.0-rc.3, even though it looks like that PR is closed. Is there a workaround?

samueloakley avatar Apr 23 '21 11:04 samueloakley