Telerik Forums
UI for ASP.NET AJAX Forum
6 answers
840 views
Hello,

I have a very simple table called Lokacije that has two columns. First one is IdLokacije (autonumber) and 2nd one is description of Location with name NazivLokacije.
Second table named Uredjaji, has a column that is foreign key of Lokacija named Lokacije.
Table: Uredjaji
    foreign key: Lokacija
Table: Lokacije
    primary key: IdLokacije (int)
    column desc: NazivLokacije
In my grid (that has datasource through SQLDataSource to Uredjaji) i have GridDropDownColumn, that is bound to Lokacija.
Everything works well, i have in edit mode dropdown list showing me NazivLokacije as DisplayValue it is bound to idLokacije.
When i want to group using Lokacija column, i am getting field IdLokacije showing me numbers, and i want to show friendly name NazivLokacije.
So my question is, how to change default grouping column display value from idLokacije to NazivLokacije?
Below is copy code of my GridDropDownColumn and also picture that should explain better

Thank you in advance
<telerik:GridDropDownColumn ColumnEditorID="GridDropDownColumnEditor1" DataField="Lokacija" DataSourceID="SqlDataSourceLokacija" DataType="System.Int64" HeaderText="Lokacija" ListTextField="NazivLokacije" ListValueField="idLokacije" UniqueName="ColumnLokacija" >                      
    <FilterTemplate>
         <telerik:RadComboBox ID="ColumnLokacija" runat="server" AppendDataBoundItems="true" DataSourceID="SqlDataSourceLokacija" DataTextField="NazivLokacije" DataValueField="idLokacije" Height="200px" OnClientSelectedIndexChanged="TitleIndexChanged" SelectedValue='<%# TryCast(Container, GridItem).OwnerTableView.GetColumn("ColumnLokacija").CurrentFilterValue%>'>
              <Items>
                 <telerik:RadComboBoxItem Text="All" />
              </Items>
         </telerik:RadComboBox>
         <telerik:RadScriptBlock ID="RadScriptBlock1" runat="server">
          <script type="text/javascript">
                 function TitleIndexChanged(sender, args) {
                    var tableView = $find("<%# TryCast(Container,GridItem).OwnerTableView.ClientID %>");
                    tableView.filter("ColumnLokacija", args.get_item().get_value(), "EqualTo"); }
          </script>
         </telerik:RadScriptBlock>
     </FilterTemplate>
</telerik:GridDropDownColumn>

 

Radoslav
Telerik team
 answered on 31 Oct 2013
1 answer
313 views
How would I display a RadAjaxLoadingPanel on c# function call where I'm doing some table updates and close it on return?

Note:

The user clicks on Save or Delete button, a conformation Dialog opens and if confirmed a function is called in c# to make the necessary changes in the database.
Shinu
Top achievements
Rank 2
 answered on 31 Oct 2013
1 answer
110 views

I have a problem with my bubble chart, the bubbles are out of the axes, do I want to know how the bubbles are cut on the axes?

The image shows how this right now my bubble chart.

Stamo Gochev
Telerik team
 answered on 31 Oct 2013
7 answers
149 views
Greetings!

My Radgrid uses a SqlDataSource that is a dynamically created pivot table. As such, the columns can be different whenever the Radgrid is loaded, and I am therfore letting the columns auto generate. Additionally, I am setting each of the fields to be editable using these two bits:

On the ItemCreated Event:
If TypeOf e.Item Is GridEditableItem Then
    e.Item.Edit = True
End If

On the PreRender Event:
CType(sender, RadGrid).Rebind()

And this works for my purposes. However, as more cells are rendered, performance takes a noticeable hit. And I'm not talking about thousands of records - only dozens. I've followed a few of the steps outlined in the "Client/server grid performance optimizations"  and set the ViewState to false, and I've enabled RadCompression. But I suspect that the culprit is the heavy edit boxes. Is there a way to make the MS TextBoxes load instead of Telerik NumericTextBoxes?

Thanks!

Karl
Vasil
Telerik team
 answered on 31 Oct 2013
1 answer
179 views
So I have used a DIV solution to make a div that centers the legend in all the major browsers, but it is
not "clean" and easy...  

Has telerik made a control that will do this and allow easy legend manipulation?

I have a attached an image...
  The primary issue is that in the
     LEGEND tag the align=center is not longer in the w3 specs and should not be used... But
     it is the easiest way in firefox to get it centered... 


<
fieldset>
<legend align="center" >Test Fieldset</legend>
<div>
<p>This is just an area that will hold other info...The primary issue is that in the
    LEGEND tag the align=center is not longer in the w3 specs and should not be used... But
    it is the easiest way in firefox to get it centered... </p>
</div>
</fieldset>

Shinu
Top achievements
Rank 2
 answered on 31 Oct 2013
1 answer
229 views
Hi ,

I am using telerik RadGrid in my application. I want to export the RadGrid Detail Table's and Parent Table's  Footer Row in the excel sheet. I have used the ExcelMLExportRowCreated event to export the footer records which contains the following code :


 if (e.Worksheet.Table.Rows.Count == radGrid.Items.Count + 2)
            {
              
             
              
                RowElement row = new RowElement();
                GridFooterItem footer =radGrid.MasterTableView.GetItems(GridItemType.Footer)[0] as GridFooterItem;
                foreach (GridColumn column in radGrid.MasterTableView.Columns)
                {
                    CellElement cell = new CellElement();
                    String cellText = footer[column.UniqueName].Text;
                    cell.Data.DataItem = cellText == "&nbsp;" ? "" : cellText;
                    row.Cells.Add(cell);
                }
               
                e.Worksheet.Table.Rows.Add(row);
            }

This works fine for the parent table as we know exact row number for the parent table, But in case of detail table we are not able to determine. Please help me in this.


Thanks,
Rahul Kasar
Top achievements
Rank 1
 answered on 31 Oct 2013
1 answer
149 views
Hi,

I was wondering if it's possible to have multiple ResourceHeaderTemplates in a Scheduler and let the correct one be chosen based on the Resource's Resource Type? I'd like to do it in markup if that is possible. 
Something like (this is not valid markup):

<ResourceHeaderTemplates>
    <ResourceHeaderTemplate ResourceType="1">
        <div class="rsMainHeader" style="text-align: left;" >
            <a href="<%# Eval("Url") %>" ><%# Eval("Text") %></a>
            <br/>
            <label id="projectLeaderLabel" runat="server" ></label>
            <label id="participantsLabel" runat="server" ></label>
        </div>
    </ResourceHeaderTemplate>
    <ResourceHeaderTemplate ResourceType="2">
        <div class="rsMainHeader" style="text-align: left;" >
            <%# Eval("Text") %>
        </div>
    </ResourceHeaderTemplate>
</ResourceHeaderTemplates>
Bozhidar
Telerik team
 answered on 31 Oct 2013
8 answers
234 views

Hi Team,

I am using Treelist with paging and implemented AllowLoadOnDemand. I am facing below issues.

I wanted to expand all items, which I tried using ExpandAllItems() at page level but could not achieve it.

And I am using TreeListSelectColumn for checkbox, whenever I am selecting header checkbox it selects treelist items but
header checkbox become unselected.

And if I select checkbox for "11 22" under node performancerisk100 , and expand anyother node it displayed as selected, refer to screen shot attached.

Can anybody help on this.
 
Regards,
Sandeep.
Konstantin Dikov
Telerik team
 answered on 31 Oct 2013
12 answers
396 views
Hi,

Currently using the 2013.1.220.40 version of Telerik and having a problem. At this point in time, it is not clear whether the issue is with just this version or also with previous versions.

On my page, I have two user controls both inside a radajaxpanel. I have configured it so that the init or page load do not run on the control I do not need it to run on when I have an ajax postback. (i.e. if I want to update the 1st user control, then nothing should be run in the second).

Now, one of the controls on the page has a RadFilter. A filter is set up in codebehind on the page_init. If I just update this particular control, everything works fine. However, if I update a different control, due to the skipping of the filter set up in page_init, I am getting an error... Object reference not set to an instance of an object.

More details of the error are...


System.Web.HttpUnhandledException (0x80004005): Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.NullReferenceException: Object reference not set to an instance of an object.
   at Telerik.Web.UI.RadFilterDataFieldEditor.CreateEditorFrom(RadFilterDataFieldEditor baseEditor)
   at Telerik.Web.UI.RadFilterDataFieldEditorCollection.RetrieveEditorForFieldName(String fieldName)
   at Telerik.Web.UI.RadFilterSingleExpressionItem.SetupFunctionInterface(Control container)
   at Telerik.Web.UI.RadFilterExpressionItem.CreateFunctionalInterface()
   at Telerik.Web.UI.RadFilterExpressionItem.InitializeItem()
   at Telerik.Web.UI.RadFilter.CreateFilterItems()
   at Telerik.Web.UI.RadFilter.CreateControlHierarchy()
   at Telerik.Web.UI.RadFilter.CreateChildControls()
   at System.Web.UI.Control.EnsureChildControls()
   at System.Web.UI.Control.FindControl(String id, Int32 pathOffset)
   at System.Web.UI.Control.FindControl(String id, Int32 pathOffset)
   at System.Web.UI.Control.FindControl(String id, Int32 pathOffset)
   at System.Web.UI.Control.FindControl(String id, Int32 pathOffset)
   at System.Web.UI.Control.FindControl(String id, Int32 pathOffset)
   at System.Web.UI.Control.FindControl(String id, Int32 pathOffset)
   at System.Web.UI.Control.FindControl(String id, Int32 pathOffset)
   at System.Web.UI.Page.FindControl(String id)
   at System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
   at System.Web.UI.Page.HandleError(Exception e)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
   at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
   at System.Web.UI.Page.ProcessRequest()
   at System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context)
   at System.Web.UI.Page.ProcessRequest(HttpContext context)
   at ASP.site_home_aspx.ProcessRequest(HttpContext context) in c:\Users\David\AppData\Local\Temp\Temporary ASP.NET Files\root\b61e1bf9\22b85fdb\App_Web_4pvgfzv1.0.cs:line 0
   at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

It seems that the filter is not really handling the postback correctly. It should not run... but why does it appear to be running?

Any help on this issue would be very much appreciated.

Thank you.
Antonio Stoilkov
Telerik team
 answered on 31 Oct 2013
1 answer
86 views
I have two rad windows, one that opens inside the other.

On the second rad window, when made visible using server side code, scrollbars appear with vast space given to the side and below.  If I close this second window and click to open this again using the same method... the window appears, but this time it is fine and without the scrollbars.  Can anyone advise what is happening here and how I could possibly resolve this?

Kind Regards

Craig
Shinu
Top achievements
Rank 2
 answered on 31 Oct 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?