Neither classes derived from Button (processing your OnClick) nor classes derived from MapTool (processing your Tool) are accepting parameters. If you need to configure any of these button or tool classes, i recommend using properties in your Module derived class (or settings if that's appropriate). Your module derived class is a singleton and easily accessible from any of your code.
internal class Module1 : Module
{
private static Module1 _this = null;
...
internal static string MyToolSetting
{
get; set;
}
}
To access this from your tool (within the same project):
internal class MapTool1 : MapTool
{
private string myParameter;
public MapTool1()
{
IsSketchTool = true;
SketchType = SketchGeometryType.Rectangle;
SketchOutputMode = SketchOutputMode.Map;
}
protected override Task OnToolActivateAsync(bool active)
{
myParameter = Module1.MyToolSetting;
return base.OnToolActivateAsync(active);
}
...
}