C# - Using foreach to loop through method arguments

Viewed 26365

Is it possible to loop through a function arguments to check if any of them is null(or check them by another custom function)? something like this:

public void test (string arg1, string arg2, object arg3, DataTable arg4)
{
    foreach (var item in argus)
        {
            if( item == null)
             {
                throw;
             }
        }
   // do the rest...
}

what is the correct keyword for "argus"? I know that this is possible by some more if statement but looking for a faster way...

4 Answers
Related