Telerik Forums
UI for ASP.NET AJAX Forum
14 answers
470 views
HI,

I created radgrid with show or hide filter option on button click.  when i click show filter option Its looking good No issues. My problem is when i re-size the column to click on the filter button there is empty space is coming in the first row (Please see the image 3). Because of that the pagination is not displaying. I tried it by removing div tags but no luck... Can any one help me how to fix this. Thanks...

<div style="width: 100%; height: 650px; overflow: auto; overflow-y: hidden">
    <telerik:RadGrid ID="gvPjtMnt" runat="server" Height="550px" Width="99%" AutoGenerateColumns="false"
        BorderWidth="2px" BorderStyle="Solid" BackColor="White" AllowPaging="True" PagerStyle-AlwaysVisible="true"
        PageSize="20" AllowSorting="True" AllowFilteringByColumn="true" OnNeedDataSource="gvPjtMnt_OnNeedDataSource"
        OnItemCommand="gvPjtMnt_ItemCommand" OnItemCreated="gvPjtMnt_ItemCreated" OnItemDataBound="gvPjtMnt_ItemDataBound">
        <HeaderStyle Height="20px" BackColor="#004000" Font-Size="8pt" Font-Bold="True" ForeColor="White"
            HorizontalAlign="Center" BorderColor="White" BorderWidth="1px" />
        <AlternatingItemStyle Font-Size="8pt" BackColor="#F5F5E9" HorizontalAlign="Center"
            BorderWidth="1px" BorderColor="White" />
        <ItemStyle HorizontalAlign="Center" />
        <ExportSettings ExportOnlyData="true" IgnorePaging="true" FileName="Project Management">
        </ExportSettings>
        <MasterTableView GridLines="None" CommandItemDisplay="Top" DataKeyNames="ProjectId"
            HorizontalAlign="Center" AllowFilteringByColumn="true">
            <CommandItemTemplate>
                <table style="width: 100%">
                    <tr>
                        <td align="right" style="width: 78%">
                            <asp:LinkButton ID="lnkshwFilter" Text="ShowFilter" Font-Underline="true" ForeColor="MidnightBlue"
                                runat="server" OnClientClick="return showFilterItem()" />
                            <asp:LinkButton ID="lnkhdFilter" Text="HideFilter" Font-Underline="true" ForeColor="MidnightBlue"
                                runat="server" OnClientClick="return hideFilterItem()" />
                        </td>
                        <td align="right" style="height: 10px;">
                            Total Records found: <asp:Label ID="lblTotRecCount" runat="server" Font-Bold="True"
                                Font-Size="10pt" ForeColor="Black" Text="0"></asp:Label>
                        </td>
                        <td align="right">
                            <asp:LinkButton ID="lnkExportAll" Text="ExportAll" Font-Underline="true" ForeColor="MidnightBlue"
                                runat="server" OnClick="ExportAll_Click" />
                        </td>
                        <td align="right" style="width: 2%">
                               
                            <asp:ImageButton ID="ExportToExcelButton" runat="server" ImageUrl="~/images/ExportToExcel.gif"
                                ToolTip="Export to Excel" OnClick="ExportExcel_Click" />
                        </td>
                    </tr>
                </table>
            </CommandItemTemplate>
            <Columns>
                ..... few columns here ............
            </Columns>
            <ItemStyle ForeColor="#3C5F22" Font-Size="8pt" BackColor="White" BorderWidth="0px"
                BorderColor="White" />
            <PagerStyle Mode="NextPrevAndNumeric" AlwaysVisible="true" />
        </MasterTableView>
        <ClientSettings AllowColumnsReorder="true">
            <ClientEvents OnGridCreated="GridCreated" />
            <Scrolling AllowScroll="true" UseStaticHeaders="true" />
            <Resizing AllowColumnResize="true" />
        </ClientSettings>
    </telerik:RadGrid>
</div>

function showFilterItem() {
    $find('<%=gvPjtMnt.ClientID %>').get_masterTableView().showFilterItem();
    document.getElementById('ctl00_PagePlaceholder_gvPjtMnt_ctl00_ctl02_ctl00_lnkhdFilter').style.display = 'block';
    document.getElementById('ctl00_PagePlaceholder_gvPjtMnt_ctl00_ctl02_ctl00_lnkshwFilter').style.display = 'none';
    return false;
 
}
function hideFilterItem() {
    document.getElementById('ctl00_PagePlaceholder_gvPjtMnt_ctl00_ctl02_ctl00_lnkhdFilter').style.display = 'none';
    document.getElementById('ctl00_PagePlaceholder_gvPjtMnt_ctl00_ctl02_ctl00_lnkshwFilter').style.display = 'block';
    $find('<%=gvPjtMnt.ClientID %>').get_masterTableView().hideFilterItem();
    return false;
}
function GridCreated(sender, args) {
    sender.get_masterTableView().hideFilterItem();
}



Dimo
Telerik team
 answered on 27 Sep 2010
5 answers
255 views
Hi,

I have a tree view control (generated from DB) which opens in a rad window.
I want to select a particular node of the tree and then click on the "Select" button.

After clicking the select button - the radwindow should close and the selected data should be displayed in a textbox.
All this is working, however when I click the select button - a pop up comes over saying to resend data to the server - which is irritating. I guess this is beacuse I am trying to pass data via server side.

Any idea how this data should be tranferred via client side? May be using JS or sort of.

Thanks.

Debashis Pyne
Top achievements
Rank 1
 answered on 27 Sep 2010
1 answer
122 views

Hi

I am using Ajaxmanage manger in my page .Below is the code
 

<telerik:RadAjaxManager runat="server">
 <ajaxsettings>
<telerik:AjaxSetting AjaxControlID="btnContact">
 <updatedcontrols>
 <telerik:AjaxUpdatedControl ControlID="pnlContact" UpdatePanelHeight="" />
</updatedcontrols>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="btnDelete">
<updatedcontrols>
 <telerik:AjaxUpdatedControl ControlID="btnDelete" UpdatePanelHeight="" />
<telerik:AjaxUpdatedControl ControlID="dgvContactList" UpdatePanelHeight="" />
</updatedcontrols>
</telerik:AjaxSetting>
</ajaxsettings>
</telerik:RadAjaxManager>

btnDelete has an OnClientClik function .it does not firing. btnDelete  is inside the pnlContact panel.

<asp:Button ID="btnDelete" runat="server" CausesValidation="False" CssClass="sbttn"
TabIndex="19" Text="Delete" OnClientClick="return JF_ConfirmDelete('dgvContactList','hidContactRowCount');"
OnClick="btnDelete_Click" />

How can i call   JF_ConfirmDelete function in OnClientClick. Please provide a solution as soon as possible

Thanks

.

 

 

 

 

Maria Ilieva
Telerik team
 answered on 27 Sep 2010
1 answer
81 views

Any help is greatly appreciated.

Aspx code:
<

 

telerik:RadMenu ID="USSRadMenu" runat="server" DataSourceID="USSsmd" Skin="">

 

 

</telerik:RadMenu>

 

 

<asp:SiteMapDataSource ID="USSsmd" runat="server" ShowStartingNode="false" SiteMapProvider="USSMenu" />

css that is NOT working:

 

.RadMenu

 

.rmGroup .RightArrow,

 

 

 

.RadMenu

 

.rmGroup .RightArrowDisabled

 

{

 

background-image: url(Images/RightArrow.gif) no-repeat rightright !important;

 

}

 

Sitemap example expecting to see right arrow to go to Level 2

 

 

<

 

siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" >

 

<

 

siteMapNode url="Root#" title="" description="">

 

<

 

siteMapNode url="ContractAdmin#" title="ContractAdmin" description="" >

 

    <

siteMapNode url="~/ContractAdmin/Branding.aspx" title="Branding" description="" >

 

        <

 

siteMapNode url="Level2#" title="Level 2" description="" />

 

    </

 

siteMapNode>

 

</

 

siteMapNode>

 

<

 

siteMapNode url="" title="LogOut" description="" />

 

</

 

siteMapNode>

 

</

 

siteMap>

 

Yana
Telerik team
 answered on 27 Sep 2010
1 answer
71 views
I have the following situation:
- RadGrid with server-side paging and context menu (per row, programmatically added);
- Some rows don't have context menu items;
- On the first page in the grid everything works fine, some rows have a context menu;
- On the second page and further, the context menu isn't showing anymore although the menu items are present in the controls collection;
- When I add a dummy menu item for every row so that the context menu contains at least one item for every row, everything works again as expected on page 2 and further;

Am I running into a weird bug or am I missing something?

Thanks!
Yana
Telerik team
 answered on 27 Sep 2010
6 answers
176 views
I am getting this error after leaving the detail grid (on page load) that displays the users information that is connected to another grid that is used for selecting a users name. THe error is reported in the ScriptResource.axd on line 2560 the bold line
RadGridNamespace.RadGridTable.prototype.InitializeEvents=function(_1a9){
for(clientEvent in _1a9){
if(typeof (_1a9[clientEvent])!="string"){
continue;
}
if(!this.Owner.IsClientEventName(clientEvent)){
if(_1a9[clientEvent]!=""){
var _1aa=_1a9[clientEvent];
if(_1aa.indexOf("(")!=-1){
this[clientEvent]=_1aa;
}else{
this[clientEvent]=eval(_1aa);
}
}else{
this[clientEvent]=null;
}
}
}
};

any ideas?
Maria Ilieva
Telerik team
 answered on 27 Sep 2010
4 answers
197 views
Hey at Telerik

I have a RadTreeView with skin Office_2007 applied.

Is there any way of disabling the hover and selected images on the nodes.

I have configured the RadTreeView with TriState checkboxes and do not need the whole hover & select logic.

Sincerly Jan
Nikolay Tsenkov
Telerik team
 answered on 27 Sep 2010
2 answers
199 views
Does anybody know of a way to insert a caption into the (autogenerated) insert item template?
Ronnie
Top achievements
Rank 1
 answered on 27 Sep 2010
3 answers
427 views
Hi,

I wish to capture both the single click and double click events of a RadGrid row.  Each row in my table shows the metadata of a document (author, date etc).  When the user clicks on the row it shows the document in an iframe, next to the Grid.  I would like it so that in addition, if the user double click the row, it opens up a new window which displays the document full screen.  However, I find that the double click event is not firing due to the setting the src of the iframe.  If I don't include that line of code then both the click doubleclick events fire as expected.

Why does the double click event not fire in this scenario and how do I get around this?

Thanks
Andrew Currie
Top achievements
Rank 1
 answered on 27 Sep 2010
3 answers
94 views
Hi everyone.

I've been searching and looking around and I'm still having problems with this.

I have a button that opens a RadWindow where the user types comments, clicks an OK button to close the window, and then the original window should redirect to the main menu.

I've tried doing this with another window and just clicking the Close button on the window, with no luck.

Here is my code:

    <telerik:RadScriptBlock ID="RadScriptBlock1" runat="server">
        <script type="text/javascript">
            //<![CDATA[
            function openRejWin() {
                var oWnd = radopen("Confirm.aspx", "RadWindow3");
            }
            function OnRejectedClose(sender, eventArgs) {
                alert("Moving on!");
                window.location = "Menu.aspx";
            }
            function OnClosing(sender, eventArgs) {
                alert("Closing!");
            }
            //]]>
        </script>
    </telerik:RadScriptBlock>
  
    <telerik:RadWindowManager ID="RadWindowManager1" VisibleStatusbar="false"
        runat="server" Skin="Hay" EnableShadow="true" >
        <Windows>
            <telerik:RadWindow ID="RadWindow3" runat="server" ReloadOnShow="true" Behaviors="Close" OnClientClose="OnRejectedClose"  
                OnClientBeforeClose="OnClosing" NavigateUrl="Confirm.aspx" DestroyOnClose="false">
            </telerik:RadWindow>
        </Windows>
    </telerik:RadWindowManager>
  

Then, the .cs code for the button does the following:

btnReject.Attributes.Add("onclick", "openRejWin(); return false");

The window does open, and it does close, but I don't see the alert messages and I don't get redirected to the Menu page.

Thank you for your help.
Ivan
Top achievements
Rank 1
 answered on 27 Sep 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?