Object from reportscript

Is there the any way to get object declared in ReportScript class after report.Load(...) execute?

Comments

  • edited 10:38PM
    what are you trying to do? change script from code?
  • edited 10:38PM
    Read public variable. For example have code:
    public class ReportScript
      {
        public int zm =  123;
    

    I want to read 'zm' like

    int v = Report.zm


  • edited 10:38PM
    Now i have to use Substring , Replace etc. to get 'zm' from ScriptText string.
  • edited 10:38PM
    Above code is string. I want change this string to c# structure to read 'zm' like varaible
  • edited 10:38PM
    i think you must change your strategy to achieve your needs.

    i am talking about desktop application, UI thread is a class that creates an instance of fastreport class, fastreport script is another class and work as plugin in and internally used by fastreport class.
    UI thread creates an instance of fastreport class, we can control that
    fastreport creates an instance of fastreport script class, UI thread can't take a control.

    the question is : how to communicate between classes which is created independently?
    I use MVVMLight toolkit, read http://social.technet.microsoft.com/wiki/c...en-classes.aspx

    it's very easy to use, UI thread register a global event, and if another class send a message then UI thread will execute a method/function, the rest is yours.

    in fastreport script, send a message (value of zm) to UI thread, for example : a code like this:
    private void Text2_Click(object sender, EventArgs e)
    {
    //send zm value to ui thread
    }

Leave a Comment