Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

help me (ContentLoadException) #1

Closed
darkhero189 opened this issue Dec 19, 2013 · 17 comments
Closed

help me (ContentLoadException) #1

darkhero189 opened this issue Dec 19, 2013 · 17 comments

Comments

@darkhero189
Copy link

Can you help me

Application: XNB Exporter.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: Microsoft.Xna.Framework.Content.ContentLoadException
Stack:
   at Microsoft.Xna.Framework.Content.ContentReader.PrepareStream(System.IO.Stream, System.String, Int32 ByRef)
   at Microsoft.Xna.Framework.Content.ContentReader.Create(Microsoft.Xna.Framework.Content.ContentManager, System.IO.Stream, System.String, System.Action`1<System.IDisposable>)
   at Microsoft.Xna.Framework.Content.ContentManager.ReadAsset[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]](System.String, System.Action`1<System.IDisposable>)
   at Microsoft.Xna.Framework.Content.ContentManager.Load[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]](System.String)
   at XNBExport.ExportGame.LoadContent()
   at Microsoft.Xna.Framework.Game.Initialize()
   at Microsoft.Xna.Framework.Game.RunGame(Boolean)
   at XNBExport.Form1.<button1_Click>b__0(System.Object)
   at System.Threading.ThreadHelper.ThreadStart_Context(System.Object)
   at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
   at System.Threading.ThreadHelper.ThreadStart(System.Object)
@Athari
Copy link
Owner

Athari commented Dec 19, 2013

Please provide enough information to reproduce the case. What file are you loading? What command line do you use?

@darkhero189
Copy link
Author

Dear you,
i'm using and get errors, can you help me?

G:\Program Files (x86)\Microsoft Visual Studio 11.0\VC>cd E:\Microsoft\Winphone8
\Soft\alba.xnaconvert.0.1

G:\Program Files (x86)\Microsoft Visual Studio 11.0\VC>e:

E:\Microsoft\Winphone8\Soft\alba.xnaconvert.0.1>Alba.XnaConvert listlibs --all
Unexpected error!
System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the
 requested types. Retrieve the LoaderExceptions property for more information.
   at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
   at System.Reflection.RuntimeModule.GetTypes()
   at System.Reflection.Assembly.GetTypes()
   at System.ComponentModel.Composition.Hosting.AssemblyCatalog.get_InnerCatalog
()
   at System.ComponentModel.Composition.Hosting.AssemblyCatalog.GetExports(Impor
tDefinition definition)
   at System.ComponentModel.Composition.Hosting.DirectoryCatalog.<>c__DisplayCla
ss3.<GetExports>b__2(ComposablePartCatalog catalog)
   at System.Linq.Enumerable.<SelectManyIterator>d__14`2.MoveNext()
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.InternalGe
tExportsCore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.InnerCatal
ogExportProvider.GetExportsCore(ImportDefinition definition, AtomicComposition a
tomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.GetExports
Core(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(Import
Definition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.AggregateExportProvider.GetExpor
tsCore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.CompositionContainer.GetExportsC
ore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(Import
Definition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TryGetExports(Expor
tProvider provider, ComposablePart part, ImportDefinition definition, AtomicComp
osition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportSub
set(PartManager partManager, IEnumerable`1 imports, AtomicComposition atomicComp
osition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportsSt
ateMachine(PartManager partManager, ComposablePart part)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImports(P
artManager partManager, ComposablePart part, Boolean shouldTrackImports)
   at System.ComponentModel.Composition.Hosting.ImportEngine.SatisfyImports(Comp
osablePart part)
   at System.ComponentModel.Composition.Hosting.ComposablePartExportProvider.<>c
__DisplayClass2.<Compose>b__0()
   at System.ComponentModel.Composition.Hosting.CompositionServices.TryInvoke(Ac
tion action)
   at System.ComponentModel.Composition.Hosting.ComposablePartExportProvider.Com
pose(CompositionBatch batch)
   at System.ComponentModel.Composition.Hosting.CompositionContainer.Compose(Com
positionBatch batch)
   at System.ComponentModel.Composition.AttributedModelServices.ComposeParts(Com
positionContainer container, Object[] attributedParts)
   at Alba.XnaConvert.Program.ComposeContentServices()
   at Alba.XnaConvert.Program.MainInternal(String[] args)
   at Alba.XnaConvert.Program.Main(String[] args)

E:\Microsoft\Winphone8\Soft\alba.xnaconvert.0.1>

@Athari
Copy link
Owner

Athari commented Dec 19, 2013

Please make sure you have installed all XNA redistributable packages listed in the project's ReadMe file.

@darkhero189
Copy link
Author

Dear Mr Athari, i had installed all XNA redistributable packages listed in the project's ReadMe file (images attach)
i had installed in windows 8.1 and winserver 2008 have an same error,
Can you help me?

E:\Microsoft\Winphone8\Soft\alba.xnaconvert.0.1>gacutil -i Alba.Framework.dll
Microsoft (R) .NET Global Assembly Cache Utility.  Version 4.0.30319.1
Copyright (c) Microsoft Corporation.  All rights reserved.

Failure adding assembly to the cache: Attempt to install an assembly without a s
trong name

installed

@Athari
Copy link
Owner

Athari commented Dec 20, 2013

Please try this version: http://www.mediafire.com/download/zwkqw8p5el9ccwl/Alba.XnaConvert.0.1.1.zip
It should give you more sensible error message about what went wrong.

P.S. You don't need to add anything to GAC manually.

@darkhero189
Copy link
Author

Dear Mr Athari,
i had get version 0.1.1 and run, i get have an error,

G:\Program Files (x86)\Microsoft Visual Studio 11.0\VC>cd E:\Microsoft\Winphone8
\Soft\Alba.XnaConvert.0.1.1

G:\Program Files (x86)\Microsoft Visual Studio 11.0\VC>e:

E:\Microsoft\Winphone8\Soft\Alba.XnaConvert.0.1.1>Alba.XnaConvert listlibs --all

Failed to load one of plugins.
Unable to load one or more of the requested types. Retrieve the LoaderExceptions
 property for more information. (1: Could not load file or assembly 'Microsoft.X
na.Framework.dll' or one of its dependencies. The specified module could not be
found. 2: Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one o
f its dependencies. The specified module could not be found.)
Detailed exception information:
System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the
 requested types. Retrieve the LoaderExceptions property for more information.
   at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
   at System.Reflection.RuntimeModule.GetTypes()
   at System.Reflection.Assembly.GetTypes()
   at System.ComponentModel.Composition.Hosting.AssemblyCatalog.get_InnerCatalog
()
   at System.ComponentModel.Composition.Hosting.AssemblyCatalog.GetExports(Impor
tDefinition definition)
   at System.ComponentModel.Composition.Hosting.DirectoryCatalog.<>c__DisplayCla
ss3.<GetExports>b__2(ComposablePartCatalog catalog)
   at System.Linq.Enumerable.<SelectManyIterator>d__14`2.MoveNext()
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.InternalGe
tExportsCore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.InnerCatal
ogExportProvider.GetExportsCore(ImportDefinition definition, AtomicComposition a
tomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.GetExports
Core(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(Import
Definition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.AggregateExportProvider.GetExpor
tsCore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.CompositionContainer.GetExportsC
ore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(Import
Definition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TryGetExports(Expor
tProvider provider, ComposablePart part, ImportDefinition definition, AtomicComp
osition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportSub
set(PartManager partManager, IEnumerable`1 imports, AtomicComposition atomicComp
osition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportsSt
ateMachine(PartManager partManager, ComposablePart part)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImports(P
artManager partManager, ComposablePart part, Boolean shouldTrackImports)
   at System.ComponentModel.Composition.Hosting.ImportEngine.SatisfyImports(Comp
osablePart part)
   at System.ComponentModel.Composition.Hosting.ComposablePartExportProvider.<>c
__DisplayClass2.<Compose>b__0()
   at System.ComponentModel.Composition.Hosting.CompositionServices.TryInvoke(Ac
tion action)
   at System.ComponentModel.Composition.Hosting.ComposablePartExportProvider.Com
pose(CompositionBatch batch)
   at System.ComponentModel.Composition.Hosting.CompositionContainer.Compose(Com
positionBatch batch)
   at System.ComponentModel.Composition.AttributedModelServices.ComposeParts(Com
positionContainer container, Object[] attributedParts)
   at Alba.XnaConvert.Program.ComposeContentServices()
   at Alba.XnaConvert.Program.MainInternal(String[] args)
   at Alba.XnaConvert.Program.Main(String[] args)
System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Xna.
Framework.dll' or one of its dependencies. The specified module could not be fou
nd.
File name: 'Microsoft.Xna.Framework.dll'


System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Xna.
Framework.dll' or one of its dependencies. The specified module could not be fou
nd.
File name: 'Microsoft.Xna.Framework.dll'



E:\Microsoft\Winphone8\Soft\Alba.XnaConvert.0.1.1>Alba.XnaConvert convert -v 4 -
d "D:\Input" -o "D:\Output"
Failed to load one of plugins.
Unable to load one or more of the requested types. Retrieve the LoaderExceptions
 property for more information. (1: Could not load file or assembly 'Microsoft.X
na.Framework.dll' or one of its dependencies. The specified module could not be
found. 2: Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one o
f its dependencies. The specified module could not be found.)
Detailed exception information:
System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the
 requested types. Retrieve the LoaderExceptions property for more information.
   at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
   at System.Reflection.RuntimeModule.GetTypes()
   at System.Reflection.Assembly.GetTypes()
   at System.ComponentModel.Composition.Hosting.AssemblyCatalog.get_InnerCatalog
()
   at System.ComponentModel.Composition.Hosting.AssemblyCatalog.GetExports(Impor
tDefinition definition)
   at System.ComponentModel.Composition.Hosting.DirectoryCatalog.<>c__DisplayCla
ss3.<GetExports>b__2(ComposablePartCatalog catalog)
   at System.Linq.Enumerable.<SelectManyIterator>d__14`2.MoveNext()
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.InternalGe
tExportsCore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.InnerCatal
ogExportProvider.GetExportsCore(ImportDefinition definition, AtomicComposition a
tomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.CatalogExportProvider.GetExports
Core(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(Import
Definition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.AggregateExportProvider.GetExpor
tsCore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.CompositionContainer.GetExportsC
ore(ImportDefinition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore
(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1
& exports)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(Import
Definition definition, AtomicComposition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TryGetExports(Expor
tProvider provider, ComposablePart part, ImportDefinition definition, AtomicComp
osition atomicComposition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportSub
set(PartManager partManager, IEnumerable`1 imports, AtomicComposition atomicComp
osition)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportsSt
ateMachine(PartManager partManager, ComposablePart part)
   at System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImports(P
artManager partManager, ComposablePart part, Boolean shouldTrackImports)
   at System.ComponentModel.Composition.Hosting.ImportEngine.SatisfyImports(Comp
osablePart part)
   at System.ComponentModel.Composition.Hosting.ComposablePartExportProvider.<>c
__DisplayClass2.<Compose>b__0()
   at System.ComponentModel.Composition.Hosting.CompositionServices.TryInvoke(Ac
tion action)
   at System.ComponentModel.Composition.Hosting.ComposablePartExportProvider.Com
pose(CompositionBatch batch)
   at System.ComponentModel.Composition.Hosting.CompositionContainer.Compose(Com
positionBatch batch)
   at System.ComponentModel.Composition.AttributedModelServices.ComposeParts(Com
positionContainer container, Object[] attributedParts)
   at Alba.XnaConvert.Program.ComposeContentServices()
   at Alba.XnaConvert.Program.MainInternal(String[] args)
   at Alba.XnaConvert.Program.Main(String[] args)
System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Xna.
Framework.dll' or one of its dependencies. The specified module could not be fou
nd.
File name: 'Microsoft.Xna.Framework.dll'


System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Xna.
Framework.dll' or one of its dependencies. The specified module could not be fou
nd.
File name: 'Microsoft.Xna.Framework.dll'

@darkhero189
Copy link
Author

and i have seen version of Microsoft.Xna.Framework.dll, detail in attach file
Can you help me?
microsoft xna folders
microsoft xna framework dll

@darkhero189
Copy link
Author

Can you help me, Mr Athari? I'm using 64 bit process

@Athari
Copy link
Owner

Athari commented Dec 20, 2013

That's weird. Just a bare FileNotFoundException without any stack or inner exceptions or even a fully qualified assembly name...

Do any XNA games work?
What happens if you specify a different XNA version on the command line?

@darkhero189
Copy link
Author

Hi Athari,
I try download source code from this site and debug it,
I had an exception from this function

private void ComposeContentServices ()
        {
            new CompositionContainer(new DirectoryCatalog(".", "Alba.XnaConvert.Loader.*.dll")).ComposeParts(this);
        }

@Athari
Copy link
Owner

Athari commented Dec 20, 2013

It's the same exception. No need to copy-paste it every time. Please answer my questions above.

@darkhero189
Copy link
Author

Dear Mr Athari,
im using visual studio 2012, create xna game studio 4, all running,
i run projects over emulator WVGA 512

Can you help me?

@Athari
Copy link
Owner

Athari commented Dec 20, 2013

I need answers to these questions: #1 (comment)

@darkhero189
Copy link
Author

i don't understand your questions 1, can you tell detail for me?

@Athari
Copy link
Owner

Athari commented Dec 20, 2013

Considering you're extracting XNA resources, you have an XNA game installed. Does it work?

@darkhero189
Copy link
Author

Can you send for me your email, i will send for you my projects,
Thanks Athari

@Athari
Copy link
Owner

Athari commented Dec 21, 2013

I can't help you if you don't provide the necessary information. Apparently there's a problem with your XNA installation which isn't directly related to XnaConvert utility. You can try googling for "FileNotFoundException Could not load file or assembly Microsoft.Xna.Framework" and trying the suggested solutions.

@Athari Athari closed this as completed Dec 21, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants