string too large to encode using UTF-8 written instead as ‘STRING_TOO_LARGE’ at Visual studio 2019 for Xamarin.android project - xamarin.android

When I am building my project at visual studio 2019 at windows or Mac then the following error occurs. "string too large to encode using UTF-8 written instead as 'STRING_TOO_LARGE'. The error is occurs at Visual studio 2019 16.7.7 for windows. But this error is not happening at visual studio 2017. But I need to compile my project to visual studio 2019. Project properties is given at below screenshot https://prnt.sc/zpbX_vz0gY7U.
I have xml files at resource folder but they are mot more than 2 KB/file.

It turns out that some characters inside the files are exceeding the maximum length.Please try to find out these characters and manage to truncate them.Use this PowerShell script.
Refer to this thread.

Related

Visual Studio 2019 Preview Remote Debugger

In Visual Studio 2017, I run the remote debugger server (MSVSMON) on my local machine as an administrator so that I can attach the debugger to IIS without Visual Studio needing to run as an administrator.
When running Visual Studio 2019 Preview, the attach the debugger dialog doesn't seem to detect the MSVSMON process and so can't connect.
Is there a new version of MSVCMON?
I've tried using Bing / Google with no luck.
Is it just a bug in 2019 that it can't detect but it should?
Any suggestions how I can resolve this would be appreciated. This is a critical part of my workflow.
I found it. They haven't published a package for the current preview but the debugger is included in the standard install at:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Preview\Common7\IDE\Remote Debugger\x64\msvsmon.exe
Visual Studio 2019 finally got an Installer Package on the Download-Site of Visual Studio: Visual Studio Remote Tools
This package should be preferred if you need the Windows Service for Debugging another machine.
The link above did not work for me. Downloaded it now from the following page:
Visual Studio 2019 Remote Debugger
In my case, no link worked for me as they all linked me to a download page for Visual Studio 2022.
If you guys are searching for the msvsmon.exe files, I found them at:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\Common7\IDE\Remote Debugger
Both for x64 and x86

Robert Giesecke's Unmanaged Exports and Visual Studio 2015 Build Error

We have been using Robert Giesecke's excellent Unmanaged Exports library for a while with our Delphi application. We just upgraded to Visual Studio 2015 and it doesn't seem to be working anymore--I can compile the exact same project in VS2013 and it works fine, can access the functions in the DLL, etc. I recompile in VS2015 (exact same code and project) and I get a build failure on the Unmanaged Exports library as shown below:
Task Parameter:SdkPath=C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.6 Tools\ (TaskId:44)
Cannot find lib.exe in 'K:\Visual Studio 2015\Common7\IDE\\..\..\VC\bin'. (TaskId:44)
Done executing task "DllExportAppDomainIsolatedTask" -- FAILED. (TaskId:44)
Done building target "RGieseckeDllExport" in project "BWSITwilio.csproj" -- FAILED.: (TargetId:73)
And as such the library will not export the functions in the DLL for me to access in Delphi. I can stay in VS2013 for a while but something seems amiss with the library in VS2015 (maybe looking in the NETFX 4.6 folder??)
I am open to ideas so I can use VS2015--I was about to uninstall 2013 but have to hold off now.
Thanks in advance for any input or advice--it is really this library that has allowed us to continue to use Delphi since we can access anything in .NET with it!
The release notes for version 1.2.7 (dated 16 August 2015) on Nuget include this:
no longer fails the build when it can't find lib.exe
I suspect you are using an older version and can solve your problem by moving to the latest.
You are probably using a version that was built before VS 2015 was released and I'm sure Robert's latest version now supports VS 2015.
For what it's worth, even if lib.exe still cannot be found that's not going to bother you since you don't need a .lib file to import into Delphi.
I was facing the same issue and was able to solve this by manually copying over some Visual Studio 2013 files into the 2015 folder. I searched for lib.exe on my computer and used Beyond Compare with the two application's program file directories.
Open C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\ in
Explorer, select all files, Copy.
Open C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\ in Explorer, Paste. When prompted to replace, choose Skip.
After doing this I was able to compile my projects that were using RGiesecke.DllExport in Visual Studio 2015 again.
I can't tell you what specific version of 2013 I had installed because I've since uninstalled, but apparently these files are leftover. I'm running MS VS Community 2015 Version 14.0.23107.0.
Not sure if its relevant at all, but the lib.exe I copied from the 2013 bin folder's version reads 12.0.21005.1.

How to convert old vb6 project to vb.net in visual studio 2008?

I have an old vb6 project and I want to convert vb6 project code to vb.net in Visual Studio 2008. By using upgrade wizard in vs2008 I opened .vbp(Old vb6) file.
It is successfully opened, but I got an error. Please give me the appropriate solution for this.
upgrade failed when I tried to convert vb6 project to vb.net using upgrade
wizard in visual studio 2008. Plz solve this issue.Thanks in advance.
It looks to me that the libraries referenced by your VB6 project are not installed and registered on your Visual Studio 2008 machine.
Does this project run in VB6 on the same machine? If not, you will need to copy all of the missing OCX files to your VS2008 machine and use regsvr32.exe to register each one individually before attempting your conversion.

How to add visual studio 5 project in visual studio 3?

I have opened a project created in visual studio 3 in visual studio 5 unknowingly. So when I am trying back to open that project in visual studio 3, it is not getting opened and also showing an error saying
THE SELECTED FILE IS VISUAL STUDIO SOLUTION FILE, BUT WAS CREATED BY A
NEWER VERSION OF VISUAL STUDIO AND CANNOT BE OPENED.
What can I do to open the file in visual studio 3?
Thanks in advance!!!!
If you don't have a backup of the project files, perhaps you can use the Visual Studio Project Converter to recover your project.
From the link:
I have to say that these versions of Visual Studio are now very much out of date - it might be better to just upgrade everything to VS2013.

How to install XNA game studio on Visual Studio 2012?

Is it possible to create XNA games using Visual Studio 2012?
Yes, it's possible with a bit of tweak. Unfortunately, you still have to have VS 2010 installed.
First, install XNA Game Studio 4.0. The easiest way is to install the Windows Phone SDK 7.1 which contains everything required.
Copy the XNA Game Extension from VS 10 to VS 11 by opening a command prompt 'as administrator' and executing the following (may vary if not x64 computer with defaults paths) :
xcopy /e "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\Extensions\Microsoft\XNA Game Studio 4.0" "C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\Extensions\Microsoft\XNA Game Studio 4.0"
Run notepad as administrator then open extension.vsixmanifest in the destination directory just created.
Upgrade the Supported product version to match the new version (or duplicate the whole VisualStudio element and change the Version attribute, as #brainslugs83 said in comments):
<SupportedProducts>
<VisualStudio Version="11.0">
<Edition>VSTS</Edition>
<Edition>VSTD</Edition>
<Edition>Pro</Edition>
<Edition>VCSExpress</Edition>
<Edition>VPDExpress</Edition>
</VisualStudio>
</SupportedProducts>
Don't forget to clear/delete your cache in %localappdata%\Microsoft\VisualStudio\12.0\Extensions.
You may have to run the command to tells Visual Studio that new extensions are available. If you see an 'access denied' message, try launching the console as an administrator.
"C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\devenv.exe" /setup
This has been tested for Windows Games, but not WP7 or Xbox games.
[Edit] According Jowsty, this works also for XBox 360 Games.
[Edit for Visual Studio 2013 & Windows 8.1] See here for documentation on installing Windows Phone SDK 7.1 on Windows 8.1. Use VS version number 12.0 in place of 11.0 for all of these steps, and they will still work correctly.
On codeplex was released new XNA Extension for Visual Studio 2012/2013. You can download it from: https://msxna.codeplex.com/releases
I found another issue, for some reason if the extensions are cached in the local AppData folder, the XNA extensions never get loaded.
You need to remove the files extensionSdks.en-US.cache and extensions.en-US.cache from the %LocalAppData%\Microsoft\VisualStudio\11.0\Extensions folder. These files are rebuilt the next time you launch
If you need access to the Visual Studio startup log to debug what's happening, run devenv.exe /log command from the C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE directory (assuming you are on a 64 bit machine). The log file generated is located here:
%AppData%\Microsoft\VisualStudio\11.0\ActivityLog.xml
There seems to be some confusion over how to get this set up for the Express version specifically. Using the Windows Desktop (WD) version of VS Express 2012, I followed the instructions in Steve B's and Rick Martin's answers with the modifications below.
In step 2 rather than copying to "C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\Extensions\Microsoft\XNA Game Studio 4.0", copy to "C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\WDExpressExtensions\Microsoft\XNA Game Studio 4.0"
In step 4, after making the changes also add the line <Edition>WDExpress</Edition> (you should be able to see where it makes sense)
In step 5, replace devenv.exe with WDExpress.exe
In Rick Martin's step, replace "%LocalAppData%\Microsoft\VisualStudio\11.0\Extensions" with "%LocalAppData%\Microsoft\WDExpress\11.0\Extensions"
I haven't done a lot of work since then, but I did manage to create a new game project and it seems fine so far.

Resources