[CLOSED] Ext.net Build Scripts with 3rd Party Controls

  1. #1

    [CLOSED] Ext.net Build Scripts with 3rd Party Controls

    I'm looking at porting the Sencha wrappper for HighCharts (https://github.com/JoeKuan/Highcharts_Sencha) for use as Ext.Net controls.

    Before I start writing one by hand, I am curious if the Ext.Net build scripts could be leveraged to do some of this for me? From a quick look it would seem it can parse out the ExtJS code into C# code (among other things), but am curious how flexible that is or if it's been utilised in a such a manner before?

    Regards

    Peter
    Last edited by Daniil; Oct 12, 2015 at 6:24 AM. Reason: [CLOSED]
  2. #2
    Hi Peter,

    That is an interesting project you are going to deal with!

    From a quick look it would seem it can parse out the ExtJS code into C# code
    At some point we considered such a possibility, but it has never been implemented. Ext.NET controls are written by hand. Though, there is the Builder, Config and ConfigOptions classes within the Factory folder which are mostly generated automatically parsing Ext.NET controls.
    Last edited by Daniil; Oct 01, 2015 at 11:53 AM.
  3. #3
    Thanks for the reply Deniil.

    I have the following collection:
            
             private HighChartSeriesCollection series;
    
            [ConfigOption("series", JsonMode.AlwaysArray)]
            [Category("HighChart")]
            [PersistenceMode(PersistenceMode.InnerProperty)]
            [Meta]
            public HighChartSeriesCollection Series
            {
                get
                {
                    if (this.series == null)
                    {
                        this.series = new HighChartSeriesCollection();
                        this.series.AfterItemAdd += this.AfterItemAdd;
                        this.series.AfterItemRemove += this.AfterItemRemove;
                        
                    }
                    return this.series;
                }
            }
    I configure it as follows:
    <a:HighChart runat="server" ID="Test" StoreID="storeTest">
                        <Series>
                            <a:ColumnSerie runat="server" ID="testItem" DataIndex="Value" />
                        </Series>
                </a:HighChart>
    However I get the following exception when the page loads:

    [Exception: ItemTag validation (_tkn_5): Reference token (testItem_ClientInit) was not found.]
       Transformer.NET.ItemTag.Validate() +215
       Transformer.NET.TextTransformer.Handle() +283
       Transformer.NET.TextTransformer.Transform(List`1 tokensType, Dictionary`2 variables) +65
       Transformer.NET.TextTransformer.Transform(List`1 tokensType) +45
       Transformer.NET.TextTransformer.Transform() +67
       Ext.Net.ExtNetTransformer.Transform(String text) +225
       Ext.Net.InitScriptFilter.Transform() +116
       Ext.Net.InitScriptFilter.Flush() +108
       System.Web.HttpWriter.FilterIntegrated(Boolean finalFiltering, IIS7WorkerRequest wr) +9653397
       System.Web.HttpResponse.FilterOutput() +104
       System.Web.CallFilterExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +49
       System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +69
    I've gone through the Ext.Net code but can't find a reason for this not to work. Any pointers would be appreciated.
    Last edited by pgodwin; Oct 06, 2015 at 3:18 AM.
  4. #4
    Worked it out. Had to change [ConfigOption("series", JsonMode.AlwaysArray)] to [ConfigOption("series", typeof(ItemCollectionJsonConverter))] and a corresponding change in the ConfigOptions.

    Seems obvious in hindsight.
    Last edited by Daniil; Oct 06, 2015 at 11:22 AM. Reason: Please use [VAR] tags

Similar Threads

  1. [CLOSED] Updating 3rd Party Controls during DirectEvent
    By jwf in forum 1.x Legacy Premium Help
    Replies: 10
    Last Post: Jun 07, 2013, 11:05 AM
  2. Replies: 5
    Last Post: Nov 12, 2012, 7:41 AM
  3. [CLOSED] Build controls in code behind
    By Antonio09 in forum 2.x Legacy Premium Help
    Replies: 5
    Last Post: Aug 07, 2012, 3:37 AM
  4. Integrating Third Party Controls
    By mmiocev in forum 1.x Help
    Replies: 2
    Last Post: Mar 03, 2009, 3:53 PM
  5. Replies: 2
    Last Post: Oct 13, 2008, 4:08 AM

Tags for this Thread

Posting Permissions