Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched. Close

how to execute a pointer to a function or a function block?

yue-qi-qi
2013-02-18
2017-04-04
  • yue-qi-qi - 2013-02-18

    The problem is that:
    1、We know that Pointer is the type of DWORD,But how can we define a Pointer to a fucntion,a function block or a method?
    2、Then how can we execute the pointer?

     
  • bacha.damin - 2017-04-03

    Hi
    Has your problem been resolved?
    how can i pass a pointer to function to my external library?

     
  • Joan M - 2017-04-04

    A pointer occupies the space a DWORD occupies (depending on the platform).

    But the DWORD is the address, not the pointer itself... when you create a pointer you create it giving it's type:

    a : pointer to fbxxx;

    Then you could simply call a:

    a^();

    Hope this helps.

     

Log in to post a comment.