Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
160 views
I have a FormTemplate set up for when the user clicks the edit icon in the radgrid.  How do I set the default button?  The use case is, user clicks the edit button, edits a field, tabs, edits a 2nd field then hits the Enter or Return key. 

asp:Panel controls have a DefaultButton property which work well for this.  Is there some way to do this?

Thanks in advance.
Shinu
Top achievements
Rank 2
 answered on 01 Oct 2010
4 answers
85 views
I am using a NestedViewTemplate in a grid that has a custom context menu. Right-clicking anywhere within the NestedViewTemplate does not trigger the context menu of the main grid as right-clicking on a row does. Is it possible to do this?
Jason Rosensweig
Top achievements
Rank 1
 answered on 01 Oct 2010
7 answers
797 views
Hi,
I'm using RadNumericTextBox and I set DataType = System.Decimal.
But in code the value is double from this TextBox.
Is it normal?
maina
Top achievements
Rank 1
 answered on 30 Sep 2010
2 answers
67 views
I have a radgird on the screen andt uses onneeddata to fill the grid.  The filtering is done by dropdowns on the screen.
Here is my grid.
<rad:radgrid id="gridFilings" runat="server"
                allowsorting="True" autogeneratecolumns="False"
                enableajax="True" enableajaxloadingtemplate="True" gridlines="None" loadingtemplatetransparency="50"
                showstatusbar="True" skin="Windows"
                width="98%" ShowGroupPanel="True" AllowPaging="false" OnItemDataBound="gridFilings_ItemDataBound"
                OnNeedDataSource ="gridFilings_NeedDataSource"
                
                  
                <ClientSettings AllowDragToGroup="True">
                    <Selecting AllowRowSelect="True" />
                </ClientSettings>
                <MasterTableView AllowCustomPaging="True" DataKeyNames="FileID"
                     AutoGenerateColumns="False" DataSourcePersistenceMode="NoPersistence" AlternatingItemStyle-BackColor="ControlLight">
                    <Columns>  
                        <rad:GridBoundColumn DataField="FileID"
                        UniqueName="FileID" Groupable="False" AllowSorting="True" Visible="True" HeaderText="Job #" HeaderStyle-CssClass="headerLeft" DataType="System.String">
                        </rad:GridBoundColumn>              
                         <rad:GridTemplateColumn DataField="ClientName" HeaderText="Client Name" HeaderStyle-CssClass="headerLeft"
                         SortExpression="ClientName" UniqueName="ClientName" GroupByExpression="ClientName Group By ClientName">
                         <itemTemplate>
                             <%# Eval("ClientName")%>
                         </itemTemplate>
                         </rad:GridTemplateColumn>
                         <rad:GridTemplateColumn DataField="GroupName" HeaderText="Group" HeaderStyle-CssClass="headerLeft"
                         SortExpression="GroupName" UniqueName="GroupName" GroupByExpression="GroupName Group By GroupName">
                         <ItemTemplate>
                             <%# Eval("GroupName")%>  
                         </ItemTemplate>
                         </rad:GridTemplateColumn>                                                                          
                         <rad:GridTemplateColumn HeaderText="Operator" HeaderStyle-CssClass="headerLeft"
                         SortExpression="AssignedTo" UniqueName="OperatorTemplate" GroupByExpression="AssignedTo Group By AssignedTo">
                         <ItemTemplate>
                             <asp:DropDownList ID="OperatorDropDown" runat="server" EnableViewState="false"></asp:DropDownList>                     
                         </ItemTemplate>
                         </rad:GridTemplateColumn>                                                                          
                         <rad:GridTemplateColumn DataField="DateIn" HeaderText="Date In" HeaderStyle-CssClass="headerLeft"
                         SortExpression="DateIn" UniqueName="DateIn" GroupByExpression="DateIn Group By DateIn" >
                         <ItemTemplate>
                             <%# String.Format("{0:MM/dd/yyyy}", Eval("DateIn"))%>  
                         </ItemTemplate>
                         </rad:GridTemplateColumn>
                         <rad:GridTemplateColumn DataField="DueDate" 
                         HeaderText="Due Date" HeaderStyle-CssClass="headerLeft" SortExpression="DueDate" UniqueName="DueDate" GroupByExpression="DueDate Group By DueDate">
                         <ItemTemplate>
                             <%# String.Format("{0:MM/dd/yyyy}", Eval("DueDate"))%>
                         </ItemTemplate>
                         </rad:GridTemplateColumn>
                         <rad:GridTemplateColumn DataField="FileTypeName" HeaderText="Form Type" HeaderStyle-CssClass="headerLeft"
                         SortExpression="FileTypeName" UniqueName="FileTypeName" Groupable="False">
                             <ItemTemplate>
                             <%# Eval("FileTypeName")%>
                             </ItemTemplate>
                         </rad:GridTemplateColumn>
                         <rad:GridTemplateColumn DataField="ConvertedPageCount" Groupable="false" HeaderText="Converted<br>Page Count" HeaderStyle-CssClass="headerRight" ItemStyle-HorizontalAlign="Right" 
                          UniqueName="ConvertedPageCount">
                             <ItemTemplate>
                                 <%# Eval("ConvertedPageCount")%>
                             </ItemTemplate>
                         </rad:GridTemplateColumn>
                         <rad:GridTemplateColumn DataField="ChangedPageCount" Groupable="false" HeaderText="Changed<br>Page Count" HeaderStyle-CssClass="headerRight" ItemStyle-HorizontalAlign="Right" 
                          UniqueName="ChangedPageCount">
                             <ItemTemplate>
                                 <%# Eval("ChangedPageCount")%>
                             </ItemTemplate>
                         </rad:GridTemplateColumn>                         
                         <rad:GridTemplateColumn DataField="ConversionType" Groupable="false" HeaderText="Conversion" ItemStyle-HorizontalAlign="Center" 
                          UniqueName="ConversionType">
                             <ItemTemplate>
                                 <%# Eval("ConversionType")%>
                             </ItemTemplate>
                         </rad:GridTemplateColumn
                        <rad:GridBoundColumn DataField="FileStatusTypeID" 
                        UniqueName="FileStatusTypeID" Groupable="False" AllowFiltering="False" Visible="False">                    
                        </rad:GridBoundColumn>
                        <rad:GridBoundColumn DataField="AssignedTo"
                        UniqueName="AssignedTo" Groupable="False" AllowFiltering="False" Visible="False">                    
                        </rad:GridBoundColumn>
                           
                        <rad:GridTemplateColumn HeaderText="Status" HeaderStyle-CssClass="headerLeft" AllowFiltering="False" SortExpression="FileStatusTypeID" UniqueName="FileStatusTypeIDTemplate" GroupByExpression="FileStatusTypeID Group By FileStatusTypeID">
                        <ItemTemplate>
                        <asp:DropDownList ID="StatusTypeID" runat="server" EnableViewState="false" DataTextField="FileStatusTypeName" DataValueField="FileStatusTypeID"></asp:DropDownList>                
                        </ItemTemplate>
                        </rad:GridTemplateColumn>                                                 
                         <rad:GridTemplateColumn AllowFiltering="False" UniqueName="ViewFiling" Groupable="false">
                           <ItemTemplate>
                                <a href="javascript:openDialog('ViewFiling.aspx?fileid=<%# Eval("FileID")%>', 800, 600, 'file', 'scrollbars=yes,resizable=yes');">
                                    <img alt="View Filing" border="0" src="RadControls/Grid/Skins/Windows/View.gif"
                                        title="View Filing" /></a>
                           </ItemTemplate>
                         </rad:GridTemplateColumn>                                                
                         <rad:GridTemplateColumn AllowFiltering="False" UniqueName="EditFiling" Groupable="false">
                           <ItemTemplate>
                                <a href="EditFiling.aspx?fileid=<%# Eval("FileID")%>">
                                    <img alt="Edit Filing" border="0" src="RadControls/Grid/Skins/Windows/Edit.gif"
                                        title="Edit Filing" /></a>
                           </ItemTemplate>
                         </rad:GridTemplateColumn>
                        <rad:GridTemplateColumn AllowFiltering="False" UniqueName="DocumentLink" Groupable="false">
                            <ItemTemplate>
                                <a href="javascript:openDialog('FileManager.aspx?fileid=<%# Eval("FileID")%>', 800, 600, 'file', 'scrollbars=yes,resizable=yes');">
                                    <img alt="View Files" border="0" src="RadControls/Grid/Skins/Windows/folder.gif"
                                        title="View Files" /></a>
                            </ItemTemplate>
                            <HeaderStyle Width="20px" />
                        </rad:GridTemplateColumn
                        <rad:GridTemplateColumn DataField="GroupID"  
                         UniqueName="GroupID" Display="false">
                         <ItemTemplate>
                             <%# Eval("GroupID")%>
                         </ItemTemplate>
                         </rad:GridTemplateColumn>                        
                    </Columns>
                    <ExpandCollapseColumn Resizable="False" Visible="False">
                        <HeaderStyle Width="20px" />
                    </ExpandCollapseColumn>
                    <RowIndicatorColumn Visible="False">
                        <HeaderStyle Width="20px" />
                    </RowIndicatorColumn>                   
                </MasterTableView>    
            </rad:radgrid>

and this is the code behind
protected void gridFilings_NeedDataSource(object source, GridNeedDataSourceEventArgs e)
        {
            SqlDataSource1.SelectCommand= "SELECT [FileID], [ClientID], [ClientName], [DateIn], [DueDate], [FileTypeName], [FileLocation], [FileStatusTypeName], [FileStatusTypeID] , [GroupID], [GroupName], [PageCount], [ConvertedPageCount], [ChangedPageCount], [ConversionType], IsNull([AssignedTo], '') as 'AssignedTo' FROM [FileDetailView] WHERE  [FileStatusTypeID] <= 90 ";
  
            if (Page.User.IsInRole("GROUP"))
                SqlDataSource1.SelectCommand += " and [GroupID] = " + Session["GroupID"].ToString();
            else if (Page.User.IsInRole("CLIENT"))
                SqlDataSource1.SelectCommand += " and [ClientID] = " + Session["ClientID"].ToString() + " and FileStatusTypeID = 0";
              
            if (ClientName.SelectedValue.Length > 0)
                SqlDataSource1.SelectCommand += " and ClientID = " + ClientName.SelectedValue;
  
            if (ClientGroup.SelectedValue.Length > 0)
                SqlDataSource1.SelectCommand +=  " and GroupID = " + ClientGroup.SelectedValue;               
  
            if (StartDueDate.Text.Length > 0)
            {
                if (EndDueDate.Text.Length > 0)
                    SqlDataSource1.SelectCommand +=  " and (DueDate >= '" + StartDueDate.Text + "' and DueDate <= '" + EndDueDate.Text + "')";                    
                else
                    SqlDataSource1.SelectCommand +=  " and DueDate = '" + StartDueDate.Text + "'";                    
            }
  
            if (StartDateIn.Text.Length > 0)
            {
                if (EndDateIn.Text.Length > 0)
                    SqlDataSource1.SelectCommand += " and (DateIn >= '" + StartDateIn.Text + "' and DateIn <= '" + EndDateIn.Text + "')";                    
                else
                    SqlDataSource1.SelectCommand +=  " and DateIn = '" + StartDateIn.Text + "'";                    
            }
  
            SqlDataSource1.SelectCommand += " Order by FileStatusTypeID";
              
            gridFilings.DataSource = SqlDataSource1;

The issue I am having is when the user click the header to sort you see the icon popup like it is working but it does not sort the grid.  I have put a stop in the NeedDataSource and when the grid sorts it runs throught this logic, so I am assumin git is lossing the sorting and just reloading the grid.  Is there a way I can get the sort informatioan and just add an orderby in the sql?
Eric Klein
Top achievements
Rank 1
 answered on 30 Sep 2010
4 answers
108 views
Hello,
I have selected value = "" on page load i first time page is loaded.
I've read that it is when

 

EnableLoadOnDemand="true"

 


but I've set this parameter to false
Regards.
Leszek
Leszek
Top achievements
Rank 1
 answered on 30 Sep 2010
5 answers
48 views
I have successfully deployed Rad Tab Strips before, but I have one that is now causing me some grief. No matter what settings I try, when I build my project the tabs only show up as Text. They do work (each tab is linked to a multi page view) but there is no "design" to them.

Has anyone seen this before? Any ideas on how to fix it?
Royal
Top achievements
Rank 1
 answered on 30 Sep 2010
3 answers
109 views
This is a 2 part question, but they should be pretty quick to answer:
1) I have a column in the grid that I have hidden and I don't want that column to show up in the autogenerated edit form.  I guess I need to catch some event to get that removed.
2) If I don't have this column visible, I still need to set the columns data so that I can do an insert ( the column is a foreign key ).  So I am just hardcoding the foreign key here.  How would I go about doing that so that the insert will work?
Thanks.

Cori
Top achievements
Rank 2
 answered on 30 Sep 2010
2 answers
189 views
I am modifying some css that will be part of a document.  Inside the document I want an icon to be displayed and when the icon is clicked some css balloon hover text is displayed.  The problem is when I switch over from HTML view to Display view the span tag is displayed even though it should not be visible (see attached picture).

Thanks.

Code:

<STYLE type=text/css>
/*
 * Public Notes
 */
/*
 * Public Notes
 */
.PublicNotes{
   font-size: medium;
   color: #00FF00;
   font-weight: bold;
}
/*
 * Personal Notes
 */
/*------From Settings Configuration Page-------*/
/*---------- bubble tooltip -----------*/
a.tt{
    position:relative;
    z-index:24;
    color:#3CA3FF;
    font-weight:bold;
    text-decoration:none;
    background:url(images/Y-Note-icon16x16.png) top left no-repeat;
  clear:both;   
}
a.tt span{
       display: none;
 
}
 
/*background:; ie hack, something must be changed in a for ie to execute it*/
a.tt:hover{ z-index:25; color: #aaaaff; background:;}
a.tt:hover span.tooltip{
    display:block;
    position:absolute;
    top:0px; left:0;
    padding: 15px 0 0 0;
    width:200px;
    color: #993300;
    text-align: center;
    filter: alpha(opacity:90);
    KHTMLOpacity: 0.90;
    MozOpacity: 0.90;
    opacity: 0.90;
}
a.tt:hover span.top{
    display: block;
    padding: 30px 8px 0;
    background: url(images/bubble.gif) no-repeat top;
}
a.tt:hover span.middle{ /* different middle bg for stretch */
    display: block;
    padding: 0 8px;
    background: url(images/bubble_filler.gif) repeat bottom;
}
a.tt:hover span.bottom{
    display: block;
    padding:3px 8px 10px;
    color: #548912;
    background: url(images/bubble.gif) no-repeat bottom;
}
.privateNoteMark{
    position:relative;
    height:16px; /*dimensions of our image*/
    width:16px;
    background:url(images/Y-Note-icon16x16.png) top left no-repeat;
}
 
/*----End From Setting Configuration Page------*/
/*
 * Personal Dorment Notes
 */
/*
 * Personal Dorment Notes
 */
.PersonalNotesDorment{
   letter-spacing: -900pt;
    visibility:  hidden;
}
</STYLE>
 <A class=tt href="#"><IMG src="images/folder.gif">
   <SPAN class=tooltip>
      <SPAN class=top></SPAN>
      <SPAN class=middle> This is my Bubble Tooltip with CSS </SPAN>  <!--- THIS TEXT SHOULD NOT BE DISPLAYED!
      <SPAN class=bottom></SPAN>
  </SPAN>
</A>
John
Top achievements
Rank 1
 answered on 30 Sep 2010
2 answers
119 views

I want to bind a RadGrid to a web service without using Linq. In all examples I can find, the web service has to return a List(Of MyObject); I've tried this, and it works great. However, the table I'm binding to may at runtime have additional columns, or columns may have different data type, so I can't use a static MyObject class to represent the table at compile time. I also don't know at compile time which columns need to be displayed in the grid. I would like to bind to a web service for performance reasons.

I've tried having the web service method return a DataView, and cast it a lot of different ways, but it's not working. How would I write the GetData / GetDataAndCount method of the web service to return the data from a DataView or other non-linq data source?

Thanks.

Alfred
Top achievements
Rank 1
 answered on 30 Sep 2010
11 answers
198 views
The ASP.NET MVC validation framework are weak.  Are you plan to providing a Validation framework for ASP.NET MVC?
Serge
Telerik team
 answered on 30 Sep 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?