Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
191 views
Hi,

I have a RadGrid control with databound from SQL server. One of the columns is string datatype that contains XML. When the data is displayed, I want the raw xml to show including the XML tags. Right now, what it does is dropping xml tags. I've changed string datatype in DB column to XML datatype. It seems to be the same


How can I set my grid to do this?

ps. Currently, the colums of my grid is autogenerated.


Thanks..
Daniel
Telerik team
 answered on 11 Jun 2010
1 answer
422 views

Few Issues with below xml:

<?xml version="1.0" encoding="utf-8"?>  
<Results> 
  <Products xmlns="">  
    <DesignDate>06/15/2005</DesignDate> 
    <SoldDate>06/30/2006</SoldDate> 
    <Product_No.>7289</Product_No.> 
    <Customer>Thomas</Customer> 
    <Product_Type>Accessories</Product_Type> 
    <Price_Today>380</Price_Today> 
  </Products> 
  <Products xmlns="">  
    <DesignDate>12/14/2004</DesignDate> 
    <SoldDate></SoldDate>  
    <Product_No.>3136</Product_No.> 
    <Customer>Karie</Customer> 
    <Product_Type>Electronics</Product_Type> 
    <Price_Today>333</Price_Today> 
  </Products> 
</Results> 

1) How to bind this xml Using DOM Model to RadGrid from serverside? I don't want to pull xmldatasource and gridview with columns on FRONT end(aspx).
2) How to dynamically bind the nodes DesignDate, SoldDate....as columns to RadGrid with Data? b'coz there can be many columns with different column names and I don't to specify each by saying: HeaderText="DesignDate". I would like to generate this dynamically from serverside.
Would be great if provided with a code to make this working.

Daniel
Telerik team
 answered on 11 Jun 2010
2 answers
88 views
I am using the following code from this example to dynamically pull products based on quote number.
 
protected void Review_RadToolTipManager_AjaxUpdate(object sender, ToolTipUpdateEventArgs e) 
    { 
        Control ctrl = Page.LoadControl("Quote_Detail.ascx"); 
        e.UpdatePanel.ContentTemplateContainer.Controls.Add(ctrl); 
        ((Label)ctrl.FindControl("lblQuoteID")).Text = e.Value; 
    } 
    protected void Review_RadGrid_ItemDataBound(object sender, GridItemEventArgs e) 
    { 
        if (e.Item is GridDataItem) 
        { 
            Review_RadToolTipManager.TargetControls.Add(e.Item.ClientID, ((DataRowView)e.Item.DataItem)["QuoteID"].ToString(), true); 
        } 
    } 

However, when I filter the grid or group it the values won't update on the rows. Do I need to rebind the grid on any function that would change row order of quote ids?
Ian Welsh
Top achievements
Rank 1
 answered on 11 Jun 2010
4 answers
236 views
Hi,

I have created a RadNumericTextbox control and set the NumberFormat's properties. Everything is displayed correctly, but how can I get programmatically the formatted text.

i.e.

A control displays: $ 1,223.34

in code:

string value = control.Text;

and the value equals 1223.34 and I want to get $ 1,223.34

Thanks in advance
Michal Siudyka
Top achievements
Rank 2
 answered on 11 Jun 2010
3 answers
135 views
Hello everyone,

In my grid I have 4 columns. Name, Phone, Address and Sales Person. While getting information from SQL, I am getting first 3 columns in one query and fourth column in second query. Order of grid should be by default alphabetically from column "Name". But it is showing in order of Sales Person. If I dont run the second query to get sales person information, my order is according to Name (i.e. first Column).

Is there anyway that I can set the default order for Column "Name" and also at the same time when someone click on any other column, order of grid should change according to that (which is working now as well).
In brief, when grid loads for first time it should be in alphabetical order of column Name and not column Sales person at the same time it should still allow user to change order by clicking on any of the columns headertext.

Thanks
Maria Ilieva
Telerik team
 answered on 11 Jun 2010
1 answer
115 views
We have a user control which contains various Telerik controls like RadTextBox,RadNumericTextBox, RagMaskedTextBox etc.
We are facing the problem with RadMaskedTextBox. When we load our user control fro the first time to show a maskedTextBox, it works correctly. The moment a post back occurs in the page the MaskedTextBox could not retain its viewState and Masked style is also lost.

Can anyone please suggest the probable reason for this behavior.

Note when we directly use the MaskedTextBox it works perfectly.
Maria Ilieva
Telerik team
 answered on 11 Jun 2010
3 answers
159 views
HI,

I have Implemented telerik radtreeview control. I need to change line when perform Drag and drop between trees.
I get some style from your site like rtDropAbove_Telerik, rtDropBelow_Telerik but i am stil confused.

Can you help me how to change line when perform drag and drop with Example

Thanks in Advance.

Regards,
sadiq modan
mohmedsadiq modan
Top achievements
Rank 1
 answered on 11 Jun 2010
5 answers
237 views

RadMenu js scripts automatically set menu items style.width to terrible 600+px in my vertical menu. This behaviour only seen in IE8 and Opera 10; in FF 3.6 links widths are computed correctly (based on parent li element css style as ".RadMenu_Default .rmVertical li { width: 223px;}" in external css file, i guess). Looks like this value - 600+px - is based on the most wide link text.  Such links - with lots of text inside - are expected to be shown like normal text ("white-space: normal"), in theirs 223px.

If I just delete link's "style" property in Dragonfly (FireBug analogue for Opera), that menu item gets desired view.

The question is - is there a way to turn off automatic width adjusement for link's? Or some other method to  solve the problem.

hanks in advance.

Dmitry Selverstov
Top achievements
Rank 1
 answered on 11 Jun 2010
5 answers
357 views
I have a radgrid, using form template for update/insert/delete.  I have a drop down list that is populated from another database and I preselect the value fine.  However, since the dropdown is loaded in the itemdatabound of the radgrid, I'm having trouble doing two-way databinding.  When I do the update button, all fields are updated in the database except the dropdownlist.  Is there a way to fix this?
Mira
Telerik team
 answered on 11 Jun 2010
3 answers
208 views
I can't seem to find any good documentation as to why this behavior is happening.  I have a a list view that is using the onneeddatasource functionality.  I use this to take care of the paging and sorting functionality of the control.
 <telerik:RadListView AllowNaturalSort="true" ID="RadListView1" runat="server" Skin="Windows7" 
                                    AllowPaging="True" onneeddatasource="RadListView1_NeedDataSource"
                               

and the event handler
  protected void RadListView1_NeedDataSource(object sender, RadListViewNeedDataSourceEventArgs e) 
        { 
            getIAListData(); 
        } 

However, the method getIAListData() get called twice when i step through the code.  Why is that?  please tell me that this is not a designed behavior or that I will have to override and create custom paging methods.

thanks
Charles
Nikolay Rusev
Telerik team
 answered on 11 Jun 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?