Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community or GitHub with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Created attachment 5810 [details]
Version Info And Two IDE Logs
When I attempt to create a new C# Android solution or open an existing C# Android solution (including the downloaded HelloWorld example) in Xamarin Studio, I receive an error "The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters." in the IDE log. This error prevents me from being able to clean or build any C# Android solutions.
Michael Hutchinson from the Xamarin Studio support forum directed me to submit a bug on this after I submitted a copy of the IDE log to him. He suspects the problem to be with establishing a connection to the MSBuild builder processes.
I am running Xamarin Studio V4.2.2 (Build 2) with Xamarin Android V4.10.1 (Starter Edition) on Windows 7 Professional SP1 (64 bit). I also tried a fresh install on a new Windows 7 Home Edition SP1 (64 bit) machine, and it has the same problems.
An excerpt from the log showing the error is:
ERROR [2014-01-09 09:47:43Z]: Error while getting assembly references
System.FormatException: The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters.
at System.Convert.FromBase64_Decode(Char* startInputPtr, Int32 inputLength, Byte* startDestPtr, Int32 destLength)
at System.Convert.FromBase64CharPtr(Char* inputPtr, Int32 inputLength)
at System.Convert.FromBase64String(String s)
at MonoDevelop.Projects.Formats.MSBuild.MSBuildProjectService.GetProjectBuilder(TargetRuntime runtime, String toolsVersion, String file)
I have attached a text file containing the following:
1. The full version information from the Xamarin Studio Help -> About page
2. The contents of an IDE log file when I created a new blank C# Android solution
3. The contents of an IDE log file when I opened the C# Android HelloWorld solution
Let me know if you need any more information or need me to try something.
I appreciate your help!
Please, try the following:
Open a console and cd to the following directory:
C:\Program Files\Xamarin Studio\bin\MSBuild\dotnet.4.0>
Now run this command:
echo 1 | MonoDevelop.Projects.Formats.MSBuild.exe 2> %USERPROFILE%/Documents/log1.txt > %USERPROFILE%/Documents/log2.txt
This will generate the log1.txt and log2.txt files in your Documents folder. Please attach the files you get to this bug report.
Created attachment 5821 [details]
Log file 1 from MSBuild.exe
I ran the command and attached log1.txt to this case. Log2.txt was empty (zero bytes), so I did not attach it.
Thank you for your help and let me know what else I can do to help bring this to resolution.
I have a replacement assembly for you to try:
Could you please replace the assembly in c:\Program Files\Xamarin Studio\bin\MSBuild\dotnet.4.0 and see if that fixes the problem? Make a copy of the old assembly before replacing it, just in case.
Created attachment 5824 [details]
New Logs after replacing MonoDevelop.Projects.Formats.MSBuild.exe
I saved the original MonoDevelop.Projects.Formats.MSBuild.exe file and put the new one in its place, and now the Base-64 error is gone, but I am getting an Error while getting assembly references
System.Runtime.Remoting.RemotingException: 2 arguments were passed to 'MonoDevelop.Projects.Formats.MSBuild.IBuildEngine::LoadProject'. 3 arguments were expected by this method.
The attached log file shows the same error occurring when creating a new project and when opening an existing project.
You said you have the same issue in a fresh install of Windows 7. However, I'm wondering if you enabled any kind of logging option in Windows, or if you are using any error diagnostic tool.
The issue is caused by the "Error: Cannot initialize OLE" message being logged in the output of the MonoDevelop.Projects.Formats.MSBuild.exe app, and this error is not logged by the app, but by the .NET or COM runtime. It is the first time this issue is reported, so I'm wondering what's special in your Windows configuration that could cause this.
Your question got me thinking, and I found the problem. My kids use both of the machines with Xamarin studio installed, and I had installed NetNanny parental control software on them to control their internet usage.
I uninstalled Net Nanny and reverted to the original MonoDevelop.Projects.Formats.MSBuild.exe and the problem went away, I am now able to successfully load, build, and clean C# Android solutions.
So I would consider this one resolved. I will update my post in the forum to indicate that NetNanny is the cause of the problem.
Thanks so much for all your help, I greatly appreciate it.