Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
139 views
Hi,
    I am using two tree view control . From the left tree view control I am dragging and dropping nodes to the right side tree view control also I am editing the nodes of the right side tree view control . I want something like that , I will put a button and when I clicked on that button I will rebind the right side tree view control with the newly added nodes forn the left tree view or edited nodes with the same heirachical manner . I mean to say if I have edited the 3rd child node out of four child nodes of a parent node then when I clicked on that button it should display the parent node and 3rd child node . Same for the newly added node parent node\child nodes .

Also If click on "Cancel" button it should revert back the changes which I made to both the tree view control.
Can you please suggest me how can I do this ?

With Thanks & Regards
Manoj



 

Manoj
Top achievements
Rank 1
 answered on 07 Jan 2009
3 answers
106 views

Using the below code, wired to treeview client side node click event, I get the Sys.WebForms.PageRequestManagerServer.ErrorException javascript error.

The alert pops up as expected, but the ajax request fails...


function

 

ClientNodeClicked(sender, args)

 

{

alert(

"ClientNodeClicked!");

 

 

var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");

 

ajaxManager.ajaxRequestWithTarget(

"<%= RadTreeView1.UniqueID %>","");

 

 

}

Iana Tsolova
Telerik team
 answered on 07 Jan 2009
3 answers
238 views

 

Hi !

this.findcontrol(RadGrid1) returns null in my cs file.  i have enclose my aspx file cs file statements for u r view.








<

asp:Content ID="cntBody" ContentPlaceHolderID="cntBody" runat="server">

 

 

<%

@ Register Assembly ="Telerik.Web.UI" Namespace ="Telerik.Web.UI" TagPrefix ="telerik"%>

 

<

script type="text/javascript">

 

 

 

var grid;

 

 

 

 

function

RowSelected(rowObject)

 

{

 

var selRow = this.GetCellByColumnUniqueName(rowObject,"itemcode");

 

 

//here selRow.innerHTML will hold the value for the selected row contact name

 

 

 

 

 

SelectOrder(selRow.innerHTML,selRow.innerHTML);

}

 

 

function

SelectOrder(sPARENT_ID, sPARENT_NAME)

 

{

 

 

if ( window.opener != null && window.opener.ChangeItemcode != null )

 

{

window.opener.ChangeItemcode(sPARENT_ID, sPARENT_NAME);

window.close();

}

 

else

 

 

 

{

alert(

'Original window has closed. Trims cannot be select' );

 

}

}

 

 

function

GridCreated()

 

{

grid =

this;

 

}

 

</

script>

 

 


 

 

<telerik:RadGrid ID ="RadGrid1" runat ="server" AutoGenerateColumns ="false" AllowPaging ="true"

 

 

 

 

allowsorting ="true" AllowFilteringByColumn ="true" Width ="500px" OnItemCommand ="RadGrid1_ItemCommand"

 

 

 

 

OnNeedDataSource="RadGrid1_NeedDataSource"

 

 

oncolumncreating="RadGrid1_ColumnCreating" >

 

 

 

 

<MasterTableView AllowFilteringByColumn ="true" >

 

 

 

 

</MasterTableView>

 

 

 

 

<PagerStyle Mode ="NumericPages" />

 

 

 

 

<ClientSettings >

 

 

 

 

<Selecting AllowRowSelect ="true" />

 

 

 

 

 

</ClientSettings>

 

 

 

 

</telerik:RadGrid>

 

 

 

 

 

<br/>

 

 

 

 

<asp:Button ID="clrFilters" runat="server" Text="Clear filters"></asp:Button>

 

 

 

 

</asp:Content>
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------
My CS file .

 

 

protected void Page_Load(object sender, System.EventArgs e)

 

{

 

 

if (!IsPostBack)

 

{

Telerik.Web.UI.

RadGrid RadGrid1 = this.FindControl("RadGrid1") as Telerik.Web.UI.RadGrid;

 

ds = GetDataSet(

"SELECT Country, City, Index FROM Customers");

 

 

// this.RadGrid1.MasterTableView.Columns.Clear();

 

 

 

 

RadGrid1.MasterTableView.Columns.Clear();

 

 

try

 

 

 

 

{

RadGrid1.DataSource = ds;

 

}

 

catch (Exception e1)

 

{

}

 

 

foreach (DataColumn dataColumn in ds.Tables[0].Columns)

 

{

RadGrid.

MyCustomFilteringColumnCS gridColumn = new RadGrid.MyCustomFilteringColumnCS();

 

RadGrid1.MasterTableView.Columns.Add(gridColumn);

gridColumn.DataField = dataColumn.ColumnName;

gridColumn.HeaderText = dataColumn.ColumnName;

}

}

}

 


 

jeeva
Top achievements
Rank 1
 answered on 07 Jan 2009
2 answers
153 views
Hello

I have a user control that has a RadRotator. On the user control, I have SQL OutputCache Dependancy. When I put one instance of my control on the page with caching, everything works as expected.

When my page has two of those controls with caching, when the page is first rendered, everything is fine. If i refresh the page and page is created from cache, I get the following javascript error:

Error: 'Telerik' is undefined
Line 661

<script type="text/javascript">

//<![CDATA[

Sys.Application.add_init(

function() {
 

Line661:

$create(Telerik.Web.UI.RadRotator, {

"clientStateFieldID":"ctl00_ContentPlaceHolder1_ctl01_WrapperUpcoming1_UpcomingWork_WorkImagesRepeater_ClientState","controlButtons":{"UpButtonID":"","DownButtonID":"","LeftButtonID":"ctl00_ContentPlaceHolder1_ctl01_WrapperUpcoming1_UpcomingWork_ImgLeft","RightButtonID":"ctl00_ContentPlaceHolder1_ctl01_WrapperUpcoming1_UpcomingWork_ImgRight","OnClientButtonClick":"","OnClientButtonOver":"","OnClientButtonOut":""},"frameDuration":0,"items":[{},{},{},{},{},{},{},{},{},{},{},{},{},{}],"rotatorType":2,"scrollDirection":1,"skin":"Default"}, null, null, $get("ctl00_ContentPlaceHolder1_ctl01_WrapperUpcoming1_UpcomingWork_WorkImagesRepeater"));

});

Sys.Application.add_init(

function() {

$create(Telerik.Web.UI.RadRotator, {

"clientStateFieldID":"ctl00_ContentPlaceHolder1_ctl01_WrapperNewReleases1_NewWork_WorkImagesRepeater_ClientState","controlButtons":{"UpButtonID":"","DownButtonID":"","LeftButtonID":"ctl00_ContentPlaceHolder1_ctl01_WrapperNewReleases1_NewWork_ImgLeft","RightButtonID":"ctl00_ContentPlaceHolder1_ctl01_WrapperNewReleases1_NewWork_ImgRight","OnClientButtonClick":"","OnClientButtonOver":"","OnClientButtonOut":""},"frameDuration":0,"items":[{}],"rotatorType":6,"scrollDirection":1,"skin":"Default"}, null, null, $get("ctl00_ContentPlaceHolder1_ctl01_WrapperNewReleases1_NewWork_WorkImagesRepeater"));

});

Sys.Application.initialize();

//]]>

 
</script>

If you can offer any assistance with this, it would be greatly apprecaited. Thanks
 

 

 

Imran
Top achievements
Rank 1
 answered on 07 Jan 2009
6 answers
166 views
Hi,

When a TreeView has MultipleSelect='true' the Control+Click node selections are not being fired.

I think this is a recent bug as this used to work in older versions of the Telerik.Web.UI library (Not sure which version started this bug).

This is very easy to reproduce. Eg:

Thanks

Guido Tapia

<

 

div>

 

 

<telerik:RadScriptManager ID="sm" runat="server" />

 

 

<telerik:RadStyleSheetManager ID="RadStyleSheetManager1" runat="server" />

 

 

<script runat="server">

 

 

protected void RadTreeView1_NodeClick(object sender, RadTreeNodeEventArgs e)

 

{

lblClicked.Text = e.Node.Text +

" CLICKED";

 

}

 

</script>

 

 

<asp:Label runat="server" ID="lblClicked" />

 

 

<telerik:RadTreeView ID="RadTreeView1" runat="server" Height="400px" Width="300px" EnableDragAndDrop="true"

 

 

Skin="Office2007" OnNodeClick="RadTreeView1_NodeClick" MultipleSelect="true">

 

 

<Nodes>

 

 

<telerik:RadTreeNode Text="Books" Expanded="true">

 

 

<Nodes>

 

 

<telerik:RadTreeNode Text="Arts" />

 

 

<telerik:RadTreeNode Text="Biographies" />

 

 

<telerik:RadTreeNode Text="Children's Books" />

 

 

</Nodes>

 

 

</telerik:RadTreeNode>

 

 

</Nodes>

 

 

</telerik:RadTreeView>

 

 

</div>

 

Manoj
Top achievements
Rank 1
 answered on 07 Jan 2009
1 answer
128 views
Hello,

I tried programmably setting the selected index or value of the RadComboBox, but neither work.  I do:

combo.set_selectedIndex(0);  //doesn't do anything (has way more than zero items)

OR

var item = combo.findItemByValue("Value");  //returns actual instance
item.set_selectedItem(item);   //doesn't do anything

What do I have to do to update the display???  Is there an update method?  Or am I missing something.  Again, the combo has plenty of items and the findItemByValue returns a valid reference.

Thanks.
Shinu
Top achievements
Rank 2
 answered on 07 Jan 2009
2 answers
126 views
hi there. i am facing a problem while adding LiteralControl to hidden ajax radgrid, i have ajax enable radgrid which is hidden by using a CSS with, the older radgrid version (.net 1.x ) its was working fine, i am not able to get it worked with the new ajax control below is the details of the problem.

when a user click on a submit button there are some checks which are performed, in that process if there is any problem the code returns the error text and then that text is attached to the hidden radgrid using the code below

RadGrid2.Controls.Add(
New LiteralControl("<script language='JavaScript'>alert('invalid date.');</script>"))

 

 

the above code was working fine with the old versions but with the new controls this error message is never  shown.

thanks
nitesh monga


 

nitesh monga
Top achievements
Rank 1
 answered on 07 Jan 2009
2 answers
445 views
Hello guys,

              Please anyone give me a clue or guideline how to save the uploaded file by radupload to database and get it from database as well .  If there is an example . It would be great.  

              For now  I did this code for the saving part.
                    for (int iLoop = 0; iLoop < RadUploadContext.Current.UploadedFiles.Count; iLoop++)
                    {
                         byte[] bytes = new byte[RadUploadContext.Current.UploadedFiles[iLoop].InputStream.Length];
 Then I put the bytes as the param in binary field.  Just need a little example or any suggestion  also any better idea about my code..


Many thanks .


PS. Sorry if my english  is not good.


Marut
Top achievements
Rank 1
 answered on 07 Jan 2009
2 answers
146 views
Hi,
How can I reach a bound column in GridDataItem and get his boud Value not the Text appear on the Grid column, Please advice me ..
Thanks

Ban
Ban
Top achievements
Rank 1
 answered on 07 Jan 2009
1 answer
74 views
In timeline view the timeheader is displayed exactly in the middle of the timeslot. Is there a way to display the timeheader on the line?
Peter
Telerik team
 answered on 07 Jan 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?