Hi,
the source is throwing the error:
'nn.asdf' does not contain a definition for 'extension_testmethod'
and i really don't unterstand why...
using System.Linq;
using System.Text;
using System;
namespace nn
{
public class asdf
{
public void testmethod()
{
}
}
}
namespace nn_extension
{
using nn;
//Extension methods must be defined in a static class
public static class asdf_extension
{
// This is the extension method.
public static void extension_testmethod(this asdf str)
{
}
}
}
namespace Extension_Methods_Simple
{
//Import the extension method namespace.
using nn;
using nn_extension;
class Program
{
static void Main(string[] args)
{
asdf.extension_testmethod();
}
}
}
any ideas?