Have you tried @clrmethod decorator?

https://github.com/pythonnet/pythonnet/blob/master/src/runtime/resources/clr.py#L54
https://github.com/pythonnet/pythonnet/blob/master/src/tests/test_clrmethod.py#L14

On Tue, Jun 19, 2018 at 10:37 AM, WARD Steve <steve.w...@oxinst.com> wrote:

> Can anyone tell me how to cast or Convert (or use a TryGet, or As
> whatever…), a PyObject (a Python function), to a C# RoutedEventHandler?
>
>
>
> The Python function:
>
>
>
> def OnStartButton(sender,args):
>
>     #do stuff
>
>     pass
>
>
>
> Thanks
>
> Steve
> ____________________________________________________________
> _______________
> This e-mail is confidential and is for the addressee only.   Please refer
> to
> www.oxinst.com/email-statement for regulatory information.
>
> _________________________________________________
> Python.NET mailing list - PythonDotNet@python.org
> https://mail.python.org/mailman/listinfo/pythondotnet
>
>
_________________________________________________
Python.NET mailing list - PythonDotNet@python.org
https://mail.python.org/mailman/listinfo/pythondotnet

Reply via email to