Actionscript count and trace the number or arguments passed to a function

Actionscript:
  1. var totalArgs = arguments.length;
  2. trace("Number of Arguments passed = " + totalArgs);
  3. for (var i:Number = 0; i <totalArgs; i++) {
  4.     trace ("Argument "+i + ": " + arguments[i]);
  5. }

Leave a Comment

Please note: Comment moderation is enabled and may delay your comment. There is no need to resubmit your comment.