Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
506 views
Is there a way to only allow one row to be expanded in a hierachical RadGrid. if one row is expanded and then you expand another it collapses the former and expands the later.
Daniel
Telerik team
 answered on 11 Feb 2010
1 answer
113 views
Hi,

It's possible to use one dataset or table as source client side and how to. I searching one solution to use one dataset loaded from session as source for my grid. It's possible to use one dataset and update values client side and save client side. Other solution using webservices are tested and not working in my cms generating error 500 and server side generating many postback.

Thanks for u help. Romi
Tsvetoslav
Telerik team
 answered on 11 Feb 2010
2 answers
73 views

When opening a RadWindow for the second time, it throws an Unspecified Error.

 

function

 

OpenNewLocationWindow(Location, StopOffNum, url, offsetElementID) {

 

 

if (StopOffNum == null)

 

StopOffNum = 0;

StopValue = StopOffNum;

 

if (url == null)

 

    url =

"../../CustomerWebUI/NewLocations/CreateNewIntransShipperLocation.aspx";

 

 

    var oWnd = radopen(url + "?Location=" + Location + "&SeqNum=" + StopOffNum, "RadWindow1");

 

 

if (offsetElementID != null) {

 

    oWnd.set_offsetElementID(offsetElementID);

}

}
If the offsetElementID exists, the error is thrown.  If the offsetElementID does not exist, the program functions properly however the placement of the window is at the bottom of the page and the user must scroll down to find the window.

Clem
Top achievements
Rank 1
 answered on 11 Feb 2010
2 answers
136 views
I have a RadAjaxManager and an event handler for the OnResponseEnd event. In this event I am trying to use the $find() method to get the RadGrid object. I also must state that it is being used in a SharePoint environment. The problem is that when the page is being loaded it can find the RadGrid successfully, but in the OnResponseEnd event it returns a null. I have tried placing the function in a RadScriptBlock, as well as a RadCodeBlock. I have tried placing the scripts inside and outside the panel that the grid is in, which is updating when the grids selectedindexchanged event is fired. The code seems to work perfectly in a web-app, but when placed in the SharePoint environment it breaks. I have seen some blogs and posts where the client id is the problem, but in this situation the id is correct. As stated before, the find method does return the object on initial page load. But when an ajax update occurs, it's like the grid is not initialized until after the ResponseEnd event fires. 

Please help, the deadline is fast approaching in a few hours. I will greatly appreciate any advice. Thanks.


    <rad:RadAjaxManager ID="AjaxManager1" runat="server"> 
        <AjaxSettings> 
            <rad:AjaxSetting AjaxControlID="grdCustomerAssignments"> 
                <UpdatedControls> 
                    <rad:AjaxUpdatedControl ControlID="pnlCustomerAssignments"/> 
                </UpdatedControls> 
            </rad:AjaxSetting> 
            <rad:AjaxSetting AjaxControlID="grdCustomerAssignments"> 
                <UpdatedControls> 
                    <rad:AjaxUpdatedControl ControlID="pnlDetails"  /> 
                </UpdatedControls> 
            </rad:AjaxSetting> 
        </AjaxSettings> 
        <ClientEvents OnResponseEnd="ResponseEnd" OnRequestStart="RequestStart" /> 
 
<asp:Panel ID="pnlCustomerAssignments" runat="server" > 
        <rad:RadGrid ID="grdCustomerAssignments" runat="server" Skin="WebBlue" AutoGenerateColumns="false" AllowMultiRowSelection="false" 
            OnNeedDataSource="grdCustomerAssignments_NeedDataSource" 
            OnSelectedIndexChanged="grdCustomerAssignments_SelectedIndexChanged"> 
         
            <ClientSettings EnablePostBackOnRowClick="true" > 
                    <ClientEvents OnRowSelected="RowSelected"/> 
                    <Scrolling AllowScroll="true" ScrollHeight="350" UseStaticHeaders="true" SaveScrollPosition="true" /> 
                    <Selecting AllowRowSelect="true" /> 
                    <Resizing AllowColumnResize="true" /> 
            </ClientSettings> 
                 
            <MasterTableView DataKeyNames="ID" > 
 
                <HeaderStyle Wrap="false" HorizontalAlign="Center" VerticalAlign="Middle" Font-Bold="true" /> 
                <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" Wrap="false" /> 
                <AlternatingItemStyle HorizontalAlign="Center" VerticalAlign="Middle" Wrap="false" /> 
                 
                <NoRecordsTemplate> 
                    <div style="font-size:80%; color:Maroon;">No Items Were Found</div> 
                </NoRecordsTemplate> 
 
            </MasterTableView> 
                     
        </rad:RadGrid> 
         
 
    </asp:Panel> 
 
 
 

        <rad:RadCodeBlock ID="RadCodeBlock1" runat="server"> 
        <script type="text/javascript"> 
            var grid1; 
            Sys.Application.add_load(function() { 
                grid1 = $find('<%= grdCustomerAssignments.ClientID %>'); 
                var tmp = "asdf"; 
            }); 
            var SelectedItemIsReseting = false; 
            var SelectedIndexes = new Object(); 
 
            function RowSelected(sender, eventArgs) { 
                if (!SelectedItemIsReseting) { 
                    SelectedIndexes = eventArgs.get_itemIndexHierarchical(); 
                } 
            } 
 
            function RequestStart(sender, eventArgs) { 
                if (SelectedItemIsReseting) { 
                    eventArgs.set_cancel(true); 
                } 
            } 
 
             
 
        </script>     
    </rad:RadCodeBlock> 
     
            <rad:RadScriptBlock ID="RadScriptBlock1" runat="server"> 
            <script type="text/javascript"> 
 
                 
                function ResponseEnd(sender, eventArgs) { 
                    SelectedItemIsReseting = true; 
                    var gridID = eventArgs.get_eventTargetElement().id; 
                    var grid = $find(gridID); 
                        if (!grid) alert("No Grid"); 
                        var MasterTableView = grid.get_masterTableView(); 
                        if (!MasterTableView) alert("No Table"); 
                        MasterTableView.selectItem(MasterTableView.get_dataItems()[SelectedIndexes].get_element()); 
                        SelectedItemIsReseting = false; 
                        clearTimeout(t); 
                     
                } 
            </script> 
        </rad:RadScriptBlock> 

Yavor
Telerik team
 answered on 11 Feb 2010
3 answers
111 views
I have a combobox.. and it has a custom skin.. (just changed the hover color).. but I have this little white dot...

I have a similar black dot on the vista skin in another site...



how to get rid of it..?

thanks


Kamen Bundev
Telerik team
 answered on 11 Feb 2010
8 answers
304 views
I have used RadCombobox in my page. There is an requirement to show only 5 items in the RadCombobox when user clicks on it for selection and scroll bar will be displayed if more than 5 items are there in the Drop down.

I have MaxHeight=100px for make it work, solution is wroking on all browsers but it is not working for IE8.
Can anyone help me in resolving this issue for IE8.
Veselin Vasilev
Telerik team
 answered on 11 Feb 2010
2 answers
227 views
Hi,

I have a page which contains Telerik RadChart. The Chart Series are dynamically created and displayed as bar graph. I also need to display the values of each bars on Bar Graph. Currently i am able to display the values at the end of each bar, but only concern being the color of value.

Clients are very perticular about the color to be black but i am not able to achieve it. As it is a immidiate requirement, please help me to display the labels on Bars in black color. Please find the graph on the attachment.

Thanks,
Krishna Samaga B.
Krishna Samaga
Top achievements
Rank 1
 answered on 11 Feb 2010
0 answers
83 views

I’m trying to implement some custom paragraphs – adding h6 and blockquote tags.

It all works fine until the editor toolbar is shared - i have a page with multiple editable areas, and dont want to cripple speed of page load by having multiple toolbars. Is there a workaround?

Updated the toolset.xml:

  <paragraphs> 
    <paragraph value="&lt;body>" name="Normal" /> 
    <paragraph value="&lt;h1>" name="Heading 1" /> 
    <paragraph value="&lt;h2>" name="Heading 2" /> 
    <paragraph value="&lt;h3>" name="Heading 3" /> 
    <paragraph value="&lt;h4>" name="Heading 4" /> 
    <paragraph value="&lt;h5>" name="Heading 5" /> 
    <paragraph value="&lt;h6>" name="Heading 6" /> 
    <paragraph value="&lt;pre>" name="Formatted" /> 
    <paragraph value="&lt;address>" name="Address" /> 
    <paragraph value="&lt;blockquote>" name="Blockquote" /> 
  </paragraphs> 

 

 

Debbie Roberts
Top achievements
Rank 1
 asked on 11 Feb 2010
2 answers
153 views
Hello Telerik,
                      I am facing an issue in scrolling.The header sections are moved out of Div area to the right side and the items are only can be viewed correctly in the div section. 
 I set the following properties   to set the Scrolling in Grid       

CS
                RadFirmGrid.ClientSettings.Scrolling.AllowScroll = true;  
                RadFirmGrid.ClientSettings.Scrolling.UseStaticHeaders = true;  
                RadFirmGrid.ClientSettings.Scrolling.SaveScrollPosition = true;  
                RadFirmGrid.ClientSettings.Scrolling.ScrollHeight = Unit.Pixel(500); 

ASPX
<div align="center">  
        <div class="page">  
            <table class="insertdata" cellspacing="0" cellpadding="0" width="100%" border="0">  
                <tr> 
                    <td class="sectionhdr" colspan="2" width="30%" align="left" style="border-bottom: 1px black solid;">  
                        Firm Profile<span style="color: #0000c0"><asp:Label ID="isd" runat="server" /></span>  
                    </td> 
                </tr> 
                <tr> 
                    <td class="spacerrow" colspan="2">  
                    </td> 
                </tr> 
            </table> 
            <asp:ScriptManager ID="ScriptManager1" EnablePartialRendering="false" runat="server">  
            </asp:ScriptManager> 
            <telerik:RadAjaxManager ID="radAjaxManager" runat="server" ClientEvents-OnRequestStart="requestStart" 
                OnAjaxSettingCreating="radAjaxManager_AjaxSettingCreating">  
                <AjaxSettings> 
                    <telerik:AjaxSetting AjaxControlID="RadFirmGrid">  
                        <UpdatedControls> 
                            <telerik:AjaxUpdatedControl ControlID="RadFirmGrid" LoadingPanelID="ajaxLoadingPanel" /> 
                        </UpdatedControls> 
                    </telerik:AjaxSetting> 
                </AjaxSettings> 
                <ClientEvents OnRequestStart="requestStart" /> 
            </telerik:RadAjaxManager> 
            <telerik:RadGrid ID="RadGrid" runat="server" ShowFooter="true" HorizontalAlign="Left" Width="100%" 
                MasterTableView-HierarchyLoadMode="ServerBind" 
                ClientSettings-AllowExpandCollapse="true" 
                Skin="Vista" AllowFilteringByColumn="true" 
                AutoGenerateColumns="False" AllowSorting="True" 
                AllowMultiRowSelection="False" AllowPaging="True" 
                OnNeedDataSource="RadGrid_NeedDataSource" OnUpdateCommand="RadGrid_UpdateCommand" 
                OnItemDataBound="RadGrid_ItemDataBound"   
                OnPreRender="RadGrid_PreRender" oninsertcommand="RadGrid_InsertCommand"   
                onitemcommand="RadGrid_ItemCommand" EnableLinqExpressions="false"   
                onitemcreated="RadGrid_ItemCreated"> 

But my Grid seemed not in working well with scrolling.


-Thanks
Dimo
Telerik team
 answered on 11 Feb 2010
1 answer
288 views
Hi

In my DB I have a field called pictures with type nvarchar(MAX) where I am keeping the URL to the image.(jpg)

I use the RadBinaryImage. I read from the sample code and it shows I have to use some Databound Control.

Which will be the basic DataBound Control (if have to be used) ?
What will be my DataValue property and how do I bind the query to RadBinaryImage.

Can you suggest? I am new to RadControls.
I was trying to do something below!!!

 

 

 

 

 

private void BindPhoto(int facultyId)   
{  
string Surname = txtSurname.Text.Trim();   
string FirstName = txtFirstName.Text.Trim();   
var query =     (from tel in dc.tdlTeldirs   
                 where (tel.Family.ToLower() == Surname.ToLower() &&    tel.First.ToLower() == FirstName.ToLower())   
                 orderby tel.First   
               select new   
               {  
                 Photo = tel.pictures  
                });  
 
             BindList(ImgPhoto, query);  *********************** I know i cant bind it like this!!!   
}  
 
 
 

But cant find out the best way!!!

Thank you

 

 

 

 

 

Sebastian
Telerik team
 answered on 11 Feb 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?