1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    2
    Vote Rating
    0
    Prashant0104 is on a distinguished road

      0  

    Default Unanswered: how to add data dynamically to store

    Unanswered: how to add data dynamically to store


    Hi,
    i have a problem in adding data dynamically to store, i use the following code

    name.set('status', 'Offline');

    this codeis work fine but when i add split button on grid then it give following error
    • Uncaught TypeError: Cannot call method 'hasCls' of null
    • Uncaught TypeError: Cannot read property 'dom' of null
    i use the following code to add split button in grid

    Code:
        {
                            
                            width : 100,
                            renderer : function(view, meta, record) {
                                var id = Ext.id();
                                Ext.defer(function() {
                                    Ext.widget('button', {
                                        renderTo : id,
                                        text : 'Action',
                                        menu : Ext.menu.Menu({
                                            items : [
                                                     {
                                                xtype : 'menuitem',
                                                text : 'Edit'
                                                
                                                
                                            },
                                            {
                                                xtype : 'menuitem',
                                                text : 'delete'
                                                
                                                
                                            }]
                                        })
                                    });
                                }, 50);
    
    
                                return Ext.String.format('<div id="{0}"></div>', id);
                            }
                        }
    please help me.
    Last edited by skirtle; 1 Oct 2012 at 2:43 AM. Reason: Reformat

  2. #2
    Sencha - Community Support Team
    Join Date
    Jan 2012
    Posts
    1,376
    Answers
    346
    Vote Rating
    113
    vietits is a name known to all vietits is a name known to all vietits is a name known to all vietits is a name known to all vietits is a name known to all vietits is a name known to all

      0  

    Default


    It's maybe because creation of split button happens before grid cells are rendered. You should check to make sure the element you want to render button into has existed.

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi