Author: Nathan

When you have to pass an array to a method, you can directly pass the values without creating the array

If you have to pass an array to the method myMethod you would usually do something similar to this: int[] myArray = new int [3] {23, 48, 96, 114};myClass.myMethod(myArray); But why create an array when you can pass the integers directly? The compiler takes care to pack the integers into an array. myClass.myMethod(23, 48, 96, 114);

How do I get the values when submitting a form (either using GET or POST)?

This is a popular question among ASP.NET beginners, because this is done fairly different with .NET. While in PHP you would use $HTTP_POST_VARS[‘field1’] and $HTTP_GET_VARS[‘field1’] to get the value passed from a form (either using POST or GET method), in ASP.NET there is a big difference.First, if you pass the value using the GET method […]

Back To Top