prodesuka

Thanks for your tutorial Spacewolf. I can run the sample project without any issues.

When I try to apply your tutorial steps to my own project however, I get the following errors in Visual Studio Express 2013 for Windows Update 3:

The type or namespace name 'InterstitialAdControl' could not be found (are you missing a using directive or an assembly reference?)

The name "LocalizedStrings" does not exist in the namespace

Any idea what the underlying cause could be? The project runs fine (although without ads) when not applying the steps described in the tutorial.

One difference between the sample project and mine I've noticed is that my .sln and .suo files are in a directory higher than de files of the rest of my project. However, simply moving the .sln and .suo files to the same dir as the rest of the files causes the project to be unusable.

spacewolf

The first error means the compiler can't find the class definition for your InterstitialAdControl class.

Open InterstitialAdControl.cs - after the using statements at the top of the file you should see a line something like "namespace xxxxxxxxxxxxxxx". This line declares the namespace of the class. The namespace should match the rest of your project namespace. For example, if your project were named "ShooterGame", than this line should look like "namespace ShooterGame". You can open up MainPage.xaml.cs and look at the namespace line there. The namespace line in InterstitialAdControl.cs should match that.

I've updated the tutorial to fix this problem. Thanks for bringing it up!

It actually doesn't matter where the solution files are located. When you created the project, you can choose to have the solution files in their own directory or in with the project files (specified by checking a box next to this option or not in the create project dialog.)

Mike Hempfling

[GLOBAL: userInfoPane.html]

Mike Hempfling

Contributor

250 posts

Corona SDK

17 November 2014 - 01:49 PM

Anybody know how to solve this error message?

Error1Retrieving the COM class factory for component with CLSID {2D0A16C9-53D9-42C1-BCC2-8D2A135E2163} failed due to the following error: 8001010e The application called an interface that was marshalled for a different thread. (Exception from HRESULT: 0x8001010E (RPC_E_WRONG_THREAD)).00

spacewolf

[GLOBAL: userInfoPane.html]

spacewolf

Contributor

298 posts

Enterprise

17 November 2014 - 04:16 PM

Did you download, compile, and run the sample application? If so it should run as-is.

If you are you are trying to integrate the admob code into a different project then I would need to see your code. Can you track down the line of code and method that is throwing the exception your getting?

spacewolf

[GLOBAL: userInfoPane.html]

spacewolf

Contributor

298 posts

Enterprise

18 November 2014 - 03:31 PM

@Mike

I'm not sure what that exception means but your best bet in tracking down the problem would be to do like I said before and set breakpoints throughout various parts of your code and step through using the debugger to see if you can catch the problem code.

For your second question, do you mean you want admob to notify you in lua when an ad as been shown or you want to call a lua method and check to see if an ad has been shown?

Mike Hempfling

Mike Hempfling

[GLOBAL: userInfoPane.html]

Mike Hempfling

Contributor

250 posts

Corona SDK

19 November 2014 - 04:41 AM

@spacewolf

It would be awesome if you could include the code examples for determining if an ad had shown in your tutorial. I have never programmed in C# so I would be very thankful if you could add it to the tutorial.