using System;
using Microsoft.SPOT;
namespace NETMFBook
{
public class Program
{
public static void Main()
{
Debug.Print(“Amazing!”);
}
}
}
This program is from .NET Micro Framework for Beginners page 9. However the compiler shows the following error.
“The name ‘Debug’ does not exist in the current context”
I am using Windows 7, Visual Studio 2013, and the emulator mode.
I did not install Microsoft .NET Gadgeteer Core because I will be using a Fez Lemur.
What using statement needs to be added to the code to get the program to compile?
Microsoft.SPOT.Native is where the Debug comes from. For some reason it seems you’ve removed that from your References - a default netmf project has that.
Your reply was on the mark. The program compiles when a Console Application is selected.
For the record the “.NET Micro Framework for Beginners” document does not say what type of application should be used. Hence because the “.NET Micro Framework for Beginners” says "NETMF includes an emulator that allows NETMF applications to run right on the PC. Lets create a project and run it on the emulator I concluded I should use an emulator application.