How to use UiPath.Core.Activies in Custom Activity using

How to use UiPath.Core.Activities.Click in Custom Activity…

I want to use a click activity in my custom activity in C#

        using UiPath.Core;

        var uiPathClick = new UiPath.Core.Activities.Click();
        uiPathClick.ClickType = UiPath.Core.ClickType.CLICK_SINGLE;

But this code has error like this.
Method not found: ‘Void ‘Void UiPath.Core.Activities.Click.set_ClickType(UiPath.Core.ClickType)’

How do I do for using click activity in my custom activity…
Is there another solution?
Thanks

1 Like

Hi,

Do you have runtime error or validation error on Visual Studio?
In my environment, it seems no problem regarding set ClickType property on VS as the following image…

img20191126-1

Regards,

Thanks your reply…
I had a error on runtime…
There is no problem on build time on Visual Studio.

Hi @batman0730,

how did you solve the issue? currently we are facing the same error.

Kind regards
Patrick

Use something like this

UiPath.Core.Activities.Click actClick = new UiPath.Core.Activities.Click
{
DelayBefore = -int var-,
ClickType = -UiPath.Core.ClickType-,
MouseButton = -UiPath.Core.MouseButton-,
SimulateClick = -bool var-
};
actClick.Target.Selector = -selector-;
actClick.Target.TimeoutMS = -int var- ;
WorkflowInvoker.Invoke(actClick);