This is a migrated thread and some comments may be shown as answers.
Win 8.1, getting BadImageFormatException
6 Answers 29 Views
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
David Brenchley
Top achievements
Rank 1
David Brenchley asked on 12 Dec 2013, 12:16 AM

Getting BadImageFormatException on Win 8.1 with additional information:is not a valid Win32 application.  Not sure what is going on.



   at System.StubHelpers.StubHelpers.GetWinRTFactoryObject(IntPtr pCPCMD)

   at Telerik.Storage.Database.GetOrCreateDatabase(String databaseName, DatabaseLocation location)

   at Telerik.Storage.Extensions.Context..ctor(String databaseName, DatabaseLocation location)

   at ScriptureMemoryWindows.ViewModels.PassageViewModel..ctor(INavigationService navigationService)


6 Answers, 1 is accepted

Sort by
0
Accepted
Rosy Topchiyska
Telerik team
answered on 12 Dec 2013, 12:20 PM

Hi David,

Thank you for contacting us.

This exception is usually thrown when the configuration of the project is not correct (when you try to build your application for Any CPU) because the Data Storage uses native code that is CPU architecture dependent. Another reason could be a problem with the references. You have to add a reference to the Microsoft Visual C++ Runtime Package. You can look at this article from our online documentation that contains information about how to setup a project with Data Storage: Data Storage - Getting Started

I hope this is useful. Please, do not hesitate to contact us if you have further questions.

Regards,
Rositsa Topchiyska
Telerik

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
David Brenchley
Top achievements
Rank 1
answered on 12 Dec 2013, 04:06 PM

Following your directions in your link only gets me a Windows 8 version.  I need Windows 8.1.


The Any CPU to x86 fixed the issue.

0
Rosy Topchiyska
Telerik team
answered on 13 Dec 2013, 01:02 PM
Hello David,

The information in our online documentation is a bit outdated. In the latest version of the controls the Data Storage is installed with the Rad Controls for Windows 8/8.1 XAML installer. We apologize for any inconvenience caused and we will update our documentation right away.

To install the 8.1 version of the Data Storage, navigate from your account to > Products & Subscriptions > DevCraft CompleteInstaller and other resources > RadControls for Windows 8 XAML > download Windows 8.1 Automatic installation. Please, make sure that you have uninstalled the current version of Data Storage before you run the installer.

I hope this helps. Feel free to contact us if you have further questions.

Regards,
Rositsa Topchiyska
Telerik

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Will
Top achievements
Rank 1
answered on 28 Jun 2015, 03:37 PM

I am getting this same error on a Windows 8.1 Phone when deploying directly to the device.

 If I set the configuration of the solution to ARM and Debug mode, I am able to deploy to the device and run the app with no problems.

 If I set the configuration of the solution to ARM and Release mode, I get an exception as soon as it calls Telerik.Storage.Extensions.Context. The message from the exception is "The specified module could not be found".

 Stack Trace:

   at System.StubHelpers.StubHelpers.GetWinRTFactoryObject(IntPtr pCPCMD)
   at Telerik_Storage.Database.GetOrCreateDatabase(String databaseName, DatabaseLocation location)
   at Telerik.Storage.Extensions.Context..ctor(String databaseName, DatabaseLocation location)

Am I supposed to configure something different in release mode to include everything?

 

0
Will
Top achievements
Rank 1
answered on 01 Jul 2015, 03:27 PM

In case anyone stumbles across this, I've found a more relevant thread and am working from it now.

http://www.telerik.com/forums/urgent-release-configuration-throws-exception-0x8007007e#3hzaJf3fb0y5BcXz7miMog

0
Ivaylo Gergov
Telerik team
answered on 02 Jul 2015, 07:19 AM
Hello David,

Could you please try to download our latest Q2 2015 release and see if this helps because we have some fixes in this direction.
If this does not help, please send me a sample project so I will be able to further investigate the issue.

I am looking forward to your reply.

Regards,
Ivaylo Gergov
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Data Storage for XAML
Asked by
David Brenchley
Top achievements
Rank 1
Answers by
Rosy Topchiyska
Telerik team
David Brenchley
Top achievements
Rank 1
Will
Top achievements
Rank 1
Ivaylo Gergov
Telerik team
Share this question
or