EPPlus sBase64.replace not a function - epplus

After upgrading a project from .Net Core 3.1 to 6.0 including upgrading EPPlus to 6.0.6. I'm getting s64base.replace not a function when I attempt to export data to excel. Looks like it's in the JS for EPPlus. Worked fine when it was .Net Core 3.1 with EPPlus 5.4.0.
I should have included that this is a Blazor Project using the BlazorDownloadFile.
The EPPlus example shows using Byte Array, but according to JavaScript the replace function is only good on strings. I did just attempt changing the byte array I was using to string; but, though it got passed the java script error, the downloaded file failed to open in Excel.
Odd it worked before the .net core 6 upgrade.

Related

Why am I getting System.PlatformNotSupportedException when using SqlClient?

I'm using the current master branch of Python.Net 3.0 from GitHub, on Python 3.10, on Windows 10.
I wrote a test DLL in .NET 5 that uses System.Data.SqlClient to perform a single call to a SQL Server instance as a proof-of-concept. I configured the runtimeconfig.json file to correctly identify the .NET version (see https://github.com/pythonnet/pythonnet/issues/984#issuecomment-778786164). But when executing the code, it throws a System.PlatformNotSupportedException.
So I rebuilt the C# code for .NET Framework 4.8, adjusted the Python code accordingly, and the same code executes fine.
My theory is that there is some kind of .NET Framework dependency embedded in the SqlClient library that usually works fine inside of .NET 5. But wrapping it in Python.Net somehow breaks this. Does anyone have a good explanation for why I'm seeing this behavior?

Razor formatting off on older code files in Visual Studio for Mac

Under a single solution, I converted .net 3.1 Blazor server project to .net 5. Also, created new .net 5 Blazor server project.
In the newer projects VS-Mac formats .razor documents perfectly, while the formatting of the documents in the older, converted projects is all out of wack.
I've tried really hard to find the reason why the newer files are OK, but the older files aren't to no avail.
Does anyone have any clue how to make the older files format like the newer ones?
I know there's an experimental code editor for razor files, but it seems to be available only for VS for windows.
Thanks
-- Added a portion of a large .razor component file after doing a document format. You'll appreciate the mess. Further down the file it's worse.
For one, the closing brackets "}" are being misplaced.
HTMKL elements aren't indented.

fully compatible powerbi.api package with aspnetcore?

i was able to get the sample asp.net embedded powerbi to work with my reports
now i have to migrate it aspnetcore
i was hopeful when i saw this post - seeing that someone was able to get it done
Embed Power BI Report In ASP.Net Core Website
so i:
started a new project with the aspnetcore
installed the powerbi package
now when compiling im getting this warning:
Package 'Microsoft.PowerBI.Api 2.0.11' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETCoreApp,Version=v2.0'. This package may not be fully compatible with your project.
i searched and couldnt find a powerbi package that was specific to aspnetcore
is there one? will there be a conflict crossing cores? or does it not matter?
UPDATE:
4.6.1 powerbi package does indeed work with aspnetcore 2
but looking forward to a powerbi package specifically coded for core
As you can see this is just a warning, not an error. That warning appears because .NET Core 2.0 applications can use some Nuget packages which target .NET Framework 4.6.1 (or less). However, this inclusion might fail if the referenced .NET 4.x package contains some API not included into .NET Core/.NET Standard 2.0
So, my advice - try to run your application. If it works well at the first glance - then, most probably that PowerBI package does not contain any not supported APIs and will work well further. If it fails right at start - then you will need to wait for the release of the new version of that package which targets .NET Standard 2.0.

Issues while upgrading System.Web.Extensions dll reference from 3.5 to 4.0

I need to migrate a website built on .net framework 3.5 to 4.0 and it should work fine in IE9
The solution got upgraded by the VS's version utility and the app compiled successfully. We are using Infragistics UltraWebGrid control v11.1 which is giving some script issue when we try to perform scroll or cell edit. The control has got lot of embedded javascript resource files which seems to be not working fine.
I created a poc website of .net framework 4.0 using the same third party dlls and everything works fine. What I can doubt on is the AJAX part. I tried to consume v4.0 of ajaxcontroltoolkit. But the issue what I am facing is, the toolkit internally references System.Web.Extensions.dll of version 4.0 and my application has many references to the dll of v3.5. Adding the reference to v4.0 doesn't replaces the references to v3.5 in the web.config. Finally I manually updated the version info in web.config which has given birth to other errors.
-Unknown server tag 'asp:ScriptManager','asp:UpdatePanel' etc..
-The type or namespace name 'Script' does not exist in the namespace 'System.Web' (are you missing an assembly reference?)
Please give me some suggestions to upgrade the dll references successfully.
Thanks,
Vaishali

How can I have two .NET projects in the same domain

I have two .NET projects in the same domain. The first project I create long time ago in VB.NET. Now I create another project that I built in C#. How can I set up my new project in the same domain so I can access the new forms that I built in C#. Do I need to submit the whole folder from the project? Do I need to change anything in the web.config? Right now I am getting this error. [PhoneControl] is the new project in C#.
http://www.martinesexpress-inc.com/PhoneControl/Default.aspx
If you look in the error page it says:
alt text http://img246.imageshack.us/img246/5868/capturevv.png
Version Information: Microsoft .NET Framework Version:1.1.4322.2407;
ASP.NET Version:1.1.4322.2407
And you are trying to use some .NET 3.5 components
Change the website to use .Net 2.0 and make sure the server have .NET 3.5 SP1 installed
If you are using IIS6:
alt text http://img185.imageshack.us/img185/1410/capture2s.png
You're declaring the language correctly in your page?