Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
194 views
I have a grid with many cols. I have the grid edit col. and the grid set to edit inline. I need to add a delete button. Can I add it inside the grid edit column (the way it shows images for update and cancel)
Daniel
Telerik team
 answered on 02 Apr 2010
2 answers
197 views
Hi to all,

I need an advice or the solution for my problem.
The idea is that I have a RadGrid and it has 3 GridCheckBoxColumn.
Check value can be assigned by only one of them in a row.
After a button (outside the grid) is pressed I need to get a loop through all rows and insert as a string, into a database field, the rows IDs at what checkbox was found "True" value.

<telerik:GridCheckBoxColumn DataField="BasePer" DataType="System.Boolean" HeaderText="BasePer" SortExpression="BasePer" UniqueName="BasePer" > 
</telerik:GridCheckBoxColumn> 
 
<telerik:GridCheckBoxColumn DataField="HighPer" DataType="System.Boolean"  HeaderText="HighPer" SortExpression="HighPer" UniqueName="HighPer"> 
</telerik:GridCheckBoxColumn> 
                
<telerik:GridCheckBoxColumn DataField="LowPer" DataType="System.Boolean" HeaderText="LowPer" SortExpression="LowPer" UniqueName="LowPer"> 
</telerik:GridCheckBoxColumn> 

Thank you in advance.
Max Free
Top achievements
Rank 1
 answered on 02 Apr 2010
3 answers
172 views
hi,
after having some experiments with the panel i think it is really great and correct me if i am wrong but i think i can achieve the same AJAX functionality with jquery templating on the client side with the panel by doing the following technique

i create a web-service and request it by the panel and what i get is pure JASON, then i deserialize the Jason and use jquery to bind the value using $each function.

now i got tow questions, how i can deserialize the value comming from server like for example
{"d":{"__type":"user","name":"james","family":" smith"}}

i use the following code but nothing happens
 functionResponseEnding(sender, args) {
 

           
            $('#RadTextBox1_text').val(get_content().name);
           
       

        }

second question is is there a way to loop through template other than using $each function ?

thanks in advanced.

Lini
Telerik team
 answered on 02 Apr 2010
1 answer
217 views

I created a radtoolbar AT RUNTIME
But the javascript $find method does not find it.
That is the javascript code:

  function pesquisar(e) {
        if (e.keyCode == 13)
        {
            //radtoolbar is a runtime created RadToolBar
            //but can´t be found...
            var toolBar = $find("<%= radtoolbar.ClientID %>");
 
            //here the toolBar IS NULL and causes an error.
            var item = toolBar.findItemByText('Pesquisar');
 
            if (Telerik.Web.UI.RadToolBarButton.isInstanceOfType(item)) {
                item.click();
            }
         }
    }

I tried the getelementbyid method, but this does not return a Telerik.Web.UI.RadToolBarButton, but a [ObjectHtml DivElement].
So, the toolBar.findItemByText('Pesquisar') can´t be executed.
the javascript code:

  function pesquisar(e) {
        if (e.keyCode == 13)
        {
            // the getElementById does not return a RadToolBarButton
            var toolBar = document.getElementById("radtoolbar");
       
            var item = toolBar.findItemByText('Pesquisar');
            if (Telerik.Web.UI.RadToolBarButton.isInstanceOfType(item)) {
                item.click();
            }
         }
    }

But when I use a design time RadToolBar created, the $find method works fine

Veselin Vasilev
Telerik team
 answered on 02 Apr 2010
3 answers
710 views
Hi All,

I am facing a wierd issue. "grid.MasterTableView.get_dataSource()" is null while binding the data on postback in data binding event.

Entire code is in RadWindow.

I am binding data to the RadGrid in "DataBinding" event. In this first i am clearing all the selected items and then binding the data using webservice call. Clearing all the selected items because, when the user selects few records in the first page and navigtes to the next page, the selection is getting retained and few records are selected even in second page. To remove selection, I am keeping the values in the array and marking them selected while navigating. This works perfectly fine.

In RadWindow, i have an 'Apply' button which refreshes the radwindow and binds the data to the radgrid. While executing clearSelectedItems() function, OnRowSelected event is fired and MasterTableView.get_dataSource() is null. Not sure why the datasource is null.

Please help to resolve this.

Thanks,
Vinitha

Pavlina
Telerik team
 answered on 02 Apr 2010
5 answers
156 views
Hi, is there a way I can query all events that will occur between now and the next 7 days?  I need to include individual recurrence events as well.
Thank you
T. Tsonev
Telerik team
 answered on 02 Apr 2010
1 answer
195 views
I am working on telerik treeview control and I want to display all the nodes that are parent in bold. The treeview is created dynamically as in the treeview is bound to a Sql Server database. How can I display the parent nodes in bold.

reply me at ur earliest
thanks
Asim Ali
Veronica
Telerik team
 answered on 02 Apr 2010
3 answers
209 views
Probably a shameful noob question: I'm generating a series of buttons on page load from a SQL datasource using XSL. I'm having an issue with radConfirm and the postback. My confirm dialog shows up, but clicking OK doesn't trigger the underlying Command.

<asp:ImageButton ID="b_RemoveMod_{@mID}" runat="server"
     ImageUrl
="~\Images\12.png" AlternateText="Remove Module" CssClass="hideMe"
    
CommandName="RemoveModule"
     CommandArgument
="{@mID}"
    
OnCommand="ImageButton_onCommand"
     onClientClick
="radconfirm('Are you sure you want to delete the module and return it to inventory?',
          confirmRemoveMod, 300, 140, null, 'Confirm Module Removal');"
 /> 

I'm not sure what the first parameter of the __doPostBack should be (and heck, I'm not that confident in the second parameter, neither). If it were always a single button, I suspect the first parameter would be something like <%= Button.ClientID %>. But how do I get the ID of the clicked image button when I don't know it's ID ahead of time? There could be one, there could be 20.
function confirmRemoveMod(arg) { 
     if (arg == true) { 
          __doPostBack('', 'ImageButton_onCommand#RemoveModule'); 
     } 
} 

Tsvetie
Telerik team
 answered on 02 Apr 2010
3 answers
167 views
Hello Team,

I need to provide a Confirm dialog to proceed by check some validations of Parent and Detail table controls.

1. How do I get the values of Child edit form control on client side?
2. I have written onclientclick event on update button, but the post back happens though it returns false.... I had set causes validation property to true?
3. Finally I am planning to write on server side validation to check for parent item value and detail table edit form control. Which event needs to be handled in this case. I shud show confirm dialog on validation. How do I achieve this?

Please provide me pointers.

Reg
Prema
Pavlina
Telerik team
 answered on 02 Apr 2010
1 answer
194 views
Hi,

We have a base page where we need to traverse through all controls on the current page instance and set them to ReadOnly mode.
This works fine for most of the controls but does not work for RadComboBox.  Process never gets into if (cntrl is RadComboBox) clause. Here is the function:
       private void SetControlReadOnly(Control cntrl) 
        { 
            if (cntrl.HasControls()) 
            { 
                foreach (Control nestedContrl in cntrl.Controls) 
                { 
                    SetControlReadOnly(nestedContrl); 
                } 
            } 
            else 
            { 
                if (cntrl is RadComboBox) 
                { 
                    RadComboBox ddl = (RadComboBox)cntrl; 
                    ddl.Enabled = false; 
                } 
                else if (cntrl is RadInputControl) 
                { 
                    SetRadInputControlReadOnly((RadInputControl)cntrl); 
                } 
                else if (cntrl is CheckBox) 
                { 
                    CheckBox chk = ((CheckBox)cntrl); 
                    chk.Enabled = false; 
                } 
                else if (cntrl is TextBox) 
                { 
                    TextBox txt = ((TextBox)cntrl); 
                    txt.Enabled = true; 
                    txt.ReadOnly = true; 
                    txt.ForeColor = System.Drawing.Color.Black; 
                } 
            } 
 
        } 
 
 
        private void SetRadInputControlReadOnly(RadInputControl input) 
        { 
            input.Enabled = true; 
            input.ReadOnly = true; 
            //input.BorderStyle = BorderStyle.None; 
            input.DisabledStyle.ForeColor = System.Drawing.Color.Black; 
        } 
Kalina
Telerik team
 answered on 02 Apr 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?