How to make optional parameter

Former Member
Former Member

Hi All,

I need to implement an extension method and it suppose to be 2 parameters,

but one is mandatory and another one would be optional parameter.

See the following my logic

public string SubCategoryList(int categoryId, bool isForumThread = false)
{

// Business logic 

}

When I am trying to call the method from Script sand box its expecting two parameters always.

Can you please help me on this.

Thanks in Advance.

Parents
No Data
Reply Children
No Data