VBScript – Writing Func/Sub that can take 0 or 1 args?

Home Forums Scripting General Scripting VBScript – Writing Func/Sub that can take 0 or 1 args?

Viewing 1 post (of 1 total)
  • Author

  • humbletech99

    I was wondering if there was some way that I can write a function or sub that can be called with or without arguments?

    I specifically want to be able to write a func/sub that can either accept 1 or 0 arguments and then handle that inside the func/sub to respond differently.

    I suspect that the best I can do is pass in an empty string, but I’d be happy to hear anyone’s wisdom on this?

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.

13 Email Threat Types to Know About Right Now

As email threats evolve and multiply, keeping track of them all—and staying protected against the many different types—becomes a complex challenge. Today, that requires more than just the traditional email gateway solution that used to be good enough.

In this eBook you will learn:

  • What are the most common and challenging email attacks for organizations?
  • How to defend against sophisticated email threats, such as spoofing, social engineering, and fraud
  • How to protect employees at the inbox level with the right technologies and security-awareness training
  • How to use a multilayered protection strategy to reduce susceptibility to email attacks and better defend your business and employees

Sponsored by: