Could not load monogame#408x128 asset as a non-content file!

I try to load monogame#408x128.xnb file in Linux but get error:
Could not load monogame#408x128 asset as a non-content file!

at Microsoft.Xna.Framework.Content.ContentManager.OpenStream (System.String assetName) [0x00045] in /media/Documents/Projects/MonoGame-master/MonoGame.Framework/Content/ContentManager.cs:240
at Microsoft.Xna.Framework.Content.ContentManager.ReadAsset[T] (System.String assetName, System.Action`1[T] recordDisposableObject) [0x0007c] in /media/Documents/Projects/MonoGame-master/MonoGame.Framework/Content/ContentManager.cs:282

I use microsoft content project for building assets. It’s my loading code:


But I can load other files from same folder. What is problem in? Maybe file name

Is it the only file with a # in its name? Are you on Linux? Is the case correct?

If the file name was improper it should say file not found as a error.

Well, the error is telling you that your trying to load a xnb as a non-content file.
Meaning you are trying to load it thru the content manager without telling the content manager how it should load it (er what it should load it as).
Which begs the question is this a image ?. What are the properties for the assest set as ?

Did you just copy paste it from another project into your current apps content folder ?
How did you import it link it into your project ?

I have folder with assets .xnb
I do foreach(string file in files)

All files without ‘#’ in file name are loading good excepting this one!
Yes. I am on linux, Linux allows mt to create files with ‘#’
I have 5 years experience with monogame and face to this thing at first time

Ha ha! All were as I said. I’ve just renamed file name to monogame(408x128) and it loaded without problem. Why is it not possible to remove this limitation for file name? More over operating system allows to do this

This issue is fixed in the develop branch of MonoGame: