Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Louis 37 posts 59 karma points
    Jan 17, 2012 @ 19:16
    Louis
    0

    Create a Macro using a class

    Hi all,

    Is it possible to create a macro using a class? So say I have my class library with a set of classes in, in the Macro it should use the class which can be added in my page templates etc

     

    Thanks!

  • Rodion Novoselov 694 posts 859 karma points
    Jan 18, 2012 @ 04:40
    Rodion Novoselov
    0

    Is it an asp.net control class or you just want to call this class from your macro?

    In first case you can create a macro based on the custom control (Developer -> Macros -> Create -> Macro Properties -> ".NET Custom Control / Assembly / Type"). 

    In the latter you can either call your class from a razor macro or turn it to an XSLT extension to use it from an XSLT macro. You can also extend your XSLT with inline code and call your class from it.

Please Sign in or register to post replies

Write your reply to:

Draft