[Python.NET] Getting the name of the user-defined functions of python script through c#

Denis Akhiyarov denis.akhiyarov at gmail.com
Fri Dec 1 09:28:56 EST 2017


Can you filter user defined methods by excluding the dunder methods?

On Fri, Dec 1, 2017, 3:45 AM prathima shettigar <prathima548 at gmail.com>
wrote:

> Hi,
>
> I wanted to get all the functions name  in my c# code from python script
> using Python.Net.
>
> I have tried the following method:
> 1)PyList.Dir():This return the built-in functions along with the user
> defined...but we want only the user defined.
> 2)PythonEngine.Eval():-It takes only the expressions as string and throws
> errors for statements.
> 3)Also tried the way provided in the link
>
> https://mail.python.org/pipermail/pythondotnet/2006-May/000492.html
>
> But facing problem in importing Cheetah template..
> Can you please confirm regarding the approaches taken?
> And also suggest me if any other approach available to achieve the same.
>
> Regards,
> Prathima
> _________________________________________________
> Python.NET mailing list - PythonDotNet at python.org
> https://mail.python.org/mailman/listinfo/pythondotnet
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pythondotnet/attachments/20171201/70700d38/attachment.html>


More information about the PythonDotNet mailing list