Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
92 views
Dear Telerik Team,

In my VS2010 solution, I refer to the newest telerik .dll libraries:
- Telerik.Web.UI.dll (version 2011,1,519,40)
- Telerik.Web.Design.dll (version 2011,1,519,40)

My VS2010 designer have nearly permanently problem to show the RadChart (and not only the RadChart) in the design of my aspx page. Refresh helps, however sometimes... :(

After drag-and-drop from Toolbox, the designer produces this error message:
"Error Creating Control - RadChart1[A]Telerik.Web.UI.RadChart cannot be cast to [B]Telerik.Web.UI.RadChart. Type A originates from 'Telerik.Web.UI, Version=2011.1.519.40, Culture=neutral, PublicKeyToken=121fae78165ba3d4' in the context 'LoadNeither' at location 'C:\Users\koterec\AppData\Local\Microsoft\VisualStudio\10.0\ProjectAssemblies\vcxqtkpk01\Telerik.Web.UI.dll'. Type B originates from 'Telerik.Web.UI, Version=2011.1.519.40, Culture=neutral, PublicKeyToken=121fae78165ba3d4' in the context 'LoadNeither' at location 'C:\Users\koterec\AppData\Local\Microsoft\VisualStudio\10.0\ProjectAssemblies\pccl1usa01\telerik.web.ui.dll'."

Provide me the solution, please.
Thanks in advance.
SCT
Top achievements
Rank 1
 answered on 07 Jul 2011
4 answers
131 views
I'm going to build a hierarchy structure. Each layer contains about 12 columns and in total I'll have 7 layers of hierarchy.

I have used RadGrid Hierarchy nested table features on some of the pages which had 1-2 nested tables and it works fine, however, on this page because mainly there are 7 layers of hierarchy I can't use RadGrid Nested Tables as the 7th Nested table gets opened in the middle of the page in that case!

What other control could I use to represent such structure?

E.g. Master Detail View, not sure?

Thanks,
Pooya
Top achievements
Rank 1
 answered on 07 Jul 2011
4 answers
117 views
Hi!

I have been trying to put some rad objects inside tooltips as i followed some tutorials, but my problem is when i put radcombobox and raddatepickerit wont work. The radcombobox just let me write thing as the raddatepicker i can't neither do dropdown or make de date window appear.

Many thanks,
Fábio
FEST
Top achievements
Rank 1
 answered on 07 Jul 2011
4 answers
111 views
Hi! I have tried to understand grid basics by following the demos in the website but i can't get the selection right. I'm trying to select an item by selecting a row (i'm not sure that is possible), and i even tried to creat a column (GridButtonColumn) where i set the button as image button and the imageurl for the image i want but i can't get it right, cause it is always appearing a checkbox instead of the image and, althought it selectes the row it does not selects the item in the row (i put a breakpoint in the grid_SelectedItemChanged and it doesn't do anything).
I also tried to do this as an gridtemplatecolumn and it makes appear the image i want but every time i click on it, instead of selecting the row and the item, it gives me an error witch i don't really know whatit means.


Code for the gridButtoncolumn (and grid):
<telerik:RadGrid runat="server"
      style="z-index: 1; left: 10px; top: 450px; position: absolute" 
      CellSpacing="0" DataSourceID="processos" 
      GridLines="None" ID="rg_processos" AutoGenerateColumns="False">
      <headercontextmenu cssclass="GridContextMenu GridContextMenu_Default">
      </headercontextmenu>
      <mastertableview 
      datasourceid="processos">
      <commanditemsettings exporttopdftext="Export to PDF" />
      <rowindicatorcolumn 
      filtercontrolalttext="Filter RowIndicator column">
      <HeaderStyle Width="20px" />
      </rowindicatorcolumn>
      <expandcollapsecolumn 
      filtercontrolalttext="Filter ExpandColumn column">
         <HeaderStyle Width="20px" />
         </expandcollapsecolumn>
         <Columns>
         <telerik:GridClientSelectColumn ButtonType="ImageButton" 
         FilterControlAltText="Filter column1 column" 
         ImageUrl="~/images/select_16_mouse.png" Text="Seleccionar" UniqueName="column1">
                  </telerik:GridClientSelectColumn>
                  <telerik:GridBoundColumn DataField="Sinistrado_ID" DataType="System.Int32" 
                       FilterControlAltText="Filter Sinistrado_ID column" 
                       HeaderText="Sinistrado_ID" SortExpression="Sinistrado_ID" 
                       UniqueName="Sinistrado_ID">
                       </telerik:GridBoundColumn>
                       <telerik:GridBoundColumn DataField="Data_sinistro" DataType="System.DateTime" 
                       FilterControlAltText="Filter Data_sinistro column" HeaderText="Data_sinistro" 
                       SortExpression="Data_sinistro" UniqueName="Data_sinistro">
                       </telerik:GridBoundColumn>
                       <telerik:GridBoundColumn DataField="Nome" 
                       FilterControlAltText="Filter Nome column" HeaderText="Criado/Alterado" 
                       SortExpression="Nome" UniqueName="Nome">
                       </telerik:GridBoundColumn>
                       <telerik:GridBoundColumn DataField="quando" DataType="System.DateTime" 
                       FilterControlAltText="Filter quando column" HeaderText="Criado/Alterado" 
                       SortExpression="quando" UniqueName="quando">
                       </telerik:GridBoundColumn>
                       </Columns>
                       <editformsettings>
                       <editcolumn 
                filtercontrolalttext="Filter EditCommandColumn column">
                    </editcolumn>
                    </editformsettings>
                    </mastertableview>
                    <clientsettings>
                    <selecting allowrowselect="True" />
                    </clientsettings>
                    <filtermenu enableimagesprites="False">
                    </filtermenu>
                </telerik:RadGrid>

code for the gridtemplatecolumn:
<Columns>
   <telerik:GridTemplateColumn ItemStyle-VerticalAlign="Middle" >
   <ItemTemplate>
   <asp:ImageButton runat="server" ImageUrl="~/images/select_16_mouse.png" />
   </ItemTemplate>
   </telerik:GridTemplateColumn>
   <telerik:GridClientSelectColumn ButtonType="ImageButton" 
   FilterControlAltText="Filter column1 column" 
   ImageUrl="~/images/select_16_mouse.png" Text="Seleccionar" UniqueName="column1">
   </telerik:GridClientSelectColumn>
      <telerik:GridBoundColumn DataField="Sinistrado_ID" DataType="System.Int32" 
      FilterControlAltText="Filter Sinistrado_ID column" 
      HeaderText="Sinistrado_ID" SortExpression="Sinistrado_ID" 
      UniqueName="Sinistrado_ID">
      </telerik:GridBoundColumn>
      <telerik:GridBoundColumn DataField="Data_sinistro" DataType="System.DateTime" 
      FilterControlAltText="Filter Data_sinistro column" HeaderText="Data_sinistro" 
      SortExpression="Data_sinistro" UniqueName="Data_sinistro">
      </telerik:GridBoundColumn>
      <telerik:GridBoundColumn DataField="Nome" 
       FilterControlAltText="Filter Nome column" HeaderText="Criado/Alterado" 
       SortExpression="Nome" UniqueName="Nome">
      </telerik:GridBoundColumn>
      <telerik:GridBoundColumn DataField="quando" DataType="System.DateTime" 
      FilterControlAltText="Filter quando column" HeaderText="Criado/Alterado" 
      SortExpression="quando" UniqueName="quando">
      </telerik:GridBoundColumn>
      </Columns>

One more thing, i only know vb.net and not very much. I can handle html so if possible and the solution calls for code i would appreciate for it to be in vb.net, if is as to be in c# or javascript so be it.

Thanks,
FEST
FEST
Top achievements
Rank 1
 answered on 07 Jul 2011
2 answers
71 views
As a follow up to the earlier question beneath, I'm trying to write some code to assign contacts to facilities.

http://www.telerik.com/community/forums/aspnet-ajax/grid/how-to-reference-parent-data-items-in-edititemtemplate.aspx

I'm following samples such as the one beneath but I'm unable to find the correct event that I need to use. I'm currently trying to use 'RadGrid1_InsertCommand' but I imagine that's not working because it's the event that would be used for inserting the parent 'Facilities'.

http://www.telerik.com/community/code-library/aspnet-ajax/grid/automatic-operations-in-hierarchical-grid-with-sqldatasource-control.aspx

Can someone tell me what event I need to be looking at?

Thanks,
Tim


Protected Sub RadGrid1_InsertCommand(ByVal source As Object, ByVal e As Telerik.Web.UI.GridCommandEventArgs)
 
    'This event is not firing when I click on the 'Insert' link. What event do I need to use instead?
 
    Dim insertedItem As GridEditFormInsertItem = DirectCast(e.Item, GridEditFormInsertItem)
 
    Dim parentItem As GridDataItem = e.Item.OwnerTableView.ParentItem
    Dim datakey As String = parentItem.OwnerTableView.DataKeyValues(parentItem.ItemIndex)("FacilityID").ToString()
    Dim contactId As Integer = (TryCast(insertedItem("colContactId").Controls(0), DropDownList)).SelectedValue
 
    Dim conn As New SqlConnection(ConfigurationManager.ConnectionStrings("ConnectionString").ConnectionString)
 
    Try
        conn.Open()
 
        Dim insertQuery As String = "INSERT into FacilityContacts(FacilityId, ContactID) values('" & datakey & "','" & contactId & "')"
        Dim cmd As New SqlCommand(insertQuery, conn)
        cmd.ExecuteNonQuery()
        conn.Close()
 
    Catch ex As Exception
        RadGrid1.Controls.Add(New LiteralControl("Unable to insert contact. Reason: " + ex.Message))
        e.Canceled = True
    Finally
    End Try
 
 
End Sub

<telerik:RadGrid ID="RadGrid1" ShowStatusBar="True" DataSourceID="dsFacilityList"
    runat="server" PageSize="7" AllowSorting="True" AllowPaging="True" GridLines="None"
    CellSpacing="0" AllowAutomaticInserts="True"
    AllowAutomaticUpdates="True" >
    <PagerStyle Mode="NumericPages"></PagerStyle>
    <MasterTableView DataSourceID="dsFacilityList" AllowMultiColumnSorting="True"
        PageSize="20" CommandItemDisplay="Top" DataKeyNames="FacilityID" EditMode="EditForms" >
        <EditItemTemplate>
 
        </EditItemTemplate>
        <DetailTables>
            <telerik:GridTableView runat="server" DataKeyNames="FacilityID"
                DataSourceID="dsFacilityContactList" CommandItemDisplay="Top"
                AutoGenerateColumns="False" AllowAutomaticDeletes="True"
                AllowAutomaticInserts="False">                   
                 
                <EditItemTemplate>
               
                </EditItemTemplate>
                 
                <ParentTableRelation>
                    <telerik:GridRelationFields DetailKeyField="FacilityID"
                        MasterKeyField="FacilityID" />
                </ParentTableRelation>
                <CommandItemSettings ExportToPdfText="Export to PDF" />
                <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
                    <HeaderStyle Width="20px" />
                </RowIndicatorColumn>
                <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
                    <HeaderStyle Width="20px" />
                </ExpandCollapseColumn>
                <Columns>
                    <telerik:GridTemplateColumn DataField="ContactID"
                        FilterControlAltText="Filter column column" UniqueName="colContactId" EditFormHeaderTextFormat="">
                        <EditItemTemplate>
                               Select Contact:
                                    <asp:DropDownList ID="cboContactID" runat="server">
                                   </asp:DropDownList>
                        </EditItemTemplate>
                        <ItemTemplate>
                            <asp:Label ID="ContactIDLabel" runat="server" Text='<%# Eval("ContactLongDesc") %>'></asp:Label>
                        </ItemTemplate>
                    </telerik:GridTemplateColumn>
 
                </Columns>
                <EditFormSettings>
                    <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                    </EditColumn>
                </EditFormSettings>
            </telerik:GridTableView>
        </DetailTables>
        <CommandItemSettings ExportToPdfText="Export to PDF"></CommandItemSettings>
        <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
        </RowIndicatorColumn>
        <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column"
            Visible="True">
        </ExpandCollapseColumn>
        <SortExpressions>
 
        </SortExpressions>
        <EditFormSettings>
            <EditColumn FilterControlAltText="Filter EditCommandColumn column">
            </EditColumn>
        </EditFormSettings>
     
    </MasterTableView>
 
    <FilterMenu EnableImageSprites="False">
    </FilterMenu>
    <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default">
    </HeaderContextMenu>
</telerik:RadGrid>

Tim
Top achievements
Rank 1
 answered on 07 Jul 2011
1 answer
79 views
Hi,
Can you please tel me how to validate the DataDescription Fields and Some others Custom Fields Which we added in Scheduler, I m using Defalut Data Forms.
Plamen
Telerik team
 answered on 07 Jul 2011
1 answer
43 views
2011 Q2, the default loading panel that blocks the entire grid when grid is refreshing takes a long time over RDP beause it paints each line by line of the "block". 

Is there a way to optimize this behavior other than changing the loading panel for all?    When viewing over LAN it's fine.

IE8 is noticeably slower than FF5.
Pavel
Telerik team
 answered on 07 Jul 2011
1 answer
262 views
I'm populating information from a webservice into a radcombobox in asp.net.  I would like to force a line break for certain items to clean up the dropdown information.

No matter what I put in the text field, it always just renders the text and never actually creates a line break.  I looked into creating an itemtemplate for the combobox, but from what I've read, it's not worth the effort when using a webservice.

Is there an escape character that I could use to force a line break?

Thanks,
Javier
Javier
Top achievements
Rank 1
 answered on 07 Jul 2011
2 answers
172 views

I have a RadGrid where I'm truncating the display of cell data in order to preserve page real estate.  I want to show the full cell content in a RadToolTip.

On the server, in the GridItemDataBound server-side event handler, I'm transforming the values of each cell for display.  On the client, I'm truncating the display data using text-overflow:ellipsis.  On the server, I'm creating a RadToolTip with the full value, and shoving it into the Page object's Controls collection:

var item = (GridDataItem)e.Item;
var cell = item["Flavor"];
cell.Text = reallyLongFlavorNameValue;

var tooltip = new RadToolTip();
tooltip.Title = "Flavor";
tooltip.Text = reallyLongFlavorNameValue;
tooltip.TargetControlID = cell.ID;
tooltip.IsClientID = false;
tooltip.RelativeTo = ToolTipRelativeDisplay.Element;
this.Controls.Add(tooltip);

I'm assuming the rest of the values can be defaults.

However, when I show the page, the tooltip never shows. 

What am I missing?


Thanks
KN425000
Top achievements
Rank 1
 answered on 07 Jul 2011
2 answers
100 views
Hi. A few questions about the Sharepoint Acceleration Kit:
  • In the regular editor available in Sharepoint 2010, when we choose to insert an image in a page, there's no easy way to choose an image from the "Site Assets"; we have to upload the image every time from our computer or copy/paste the image URL. Does the SAK tool provide an easy way to choose an image from the Site Assets (or other library)?
  • I've read that the CTP will move to a final release later this year. Is that true?
Thank you :)
Alex
Top achievements
Rank 1
 answered on 07 Jul 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?