G
Guest
Hi,
I have found a need to define a class for use in a page code-behind class
file. I have a well structured model which consists of business logic
components and data access components. The class I need to define will only
be needed for this particular page. I am unsure where to put this utility
class definition and was thinking the best place for it is within my
code-behind file, such that;
namespace MyAppUI
{
public partial class MyPage
{
private MyUtilityClass muc = new MyUtilityClass();
...
...
}
public class MyUtilityClass
{
...
}
}
I haven't been able to find anybody else talk about the right places for
class definitions. Is this method acceptable?
Many thanks in advance.
I have found a need to define a class for use in a page code-behind class
file. I have a well structured model which consists of business logic
components and data access components. The class I need to define will only
be needed for this particular page. I am unsure where to put this utility
class definition and was thinking the best place for it is within my
code-behind file, such that;
namespace MyAppUI
{
public partial class MyPage
{
private MyUtilityClass muc = new MyUtilityClass();
...
...
}
public class MyUtilityClass
{
...
}
}
I haven't been able to find anybody else talk about the right places for
class definitions. Is this method acceptable?
Many thanks in advance.