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

I am trying to implement radajax manager. Here is the structure of my program

Global_masterpage
Module_masterpage
Content page

the rad script manager is in global masterpage and module masterpage has one scriptmanagerproxy for a composite script and the module masterpage has the radajaxloading panel to show ajax progress.

now in the content page, i got the code below. (extracted from a big page for testing and locating the problem). i'm trying to show the advanced search panel (pnlSearchCriteria) when you click on the lnkShowAdvancedSearch and Hide it from lnkHideAdvancedSearch (which is inside pnlSearchCriteria) The first time, the control behaves as expected. the next time i click on lnkshowadvancedsearch button, the pnlsearchcriteria does not show up and the progress area (radajaxloadingpanel) shiows activity and goes on forever. in the project configuration wizard i have all of them enabled.


here is the aspx code and followed by the vb code

<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/MasterPage.master" 
    CodeBehind="WebForm2.aspx.vb" Inherits="ERP.OM.WebForm2" %> 
 
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server"> 
</asp:Content> 
<asp:Content ID="Content2" ContentPlaceHolderID="cphBody" runat="server"> 
    <span style="padding-right: 10px">|</span> 
    <asp:LinkButton ID="lnkShowAdvancedSearch" runat="server" CausesValidation="false" 
        Text="Advanced Search" /> 
    <asp:Panel runat="server" ID="pnlSearchCriteria" Visible="false" CssClass="SearchSOAdvancedSearchPanel"> 
        <table id="tblAdvancedSearch" runat="server" width="100%"> 
            <tr> 
                <td style="border-right: solid 1px #EEEEEE; border-bottom: solid 1px #EEEEEE"> 
                    <span>Sales Person</span> 
                    <br /> 
                    <erp:Employees ID="ddlSearchSalesPerson" runat="server" AutoPostBack="true" /> 
                </td> 
                <td style="border-right: solid 1px #EEEEEE; border-bottom: solid 1px #EEEEEE"> 
                    <span>Status</span> 
                    <br /> 
                    <erp:SalesOrderStatuses runat="server" ID="ddlSearchSalesOrderStatus" AutoPostBack="true" /> 
                </td> 
                <td style="border-right: solid 1px #EEEEEE; border-bottom: solid 1px #EEEEEE"> 
                    <span>Order Type </span> 
                    <br /> 
                    <erp:SalesOrderTypes runat="server" ID="txtSearchSalesOrderTypes" AutoPostBack="true" /> 
                </td> 
                <td style="border-right: solid 1px #EEEEEE; border-bottom: solid 1px #EEEEEE"> 
                    <span>Created By</span> 
                    <br /> 
                    <erp:Employees ID="ddlSearchCreatedBy" runat="server" AutoPostBack="true" /> 
                </td> 
                <td width="100px" align="center" valign="bottom"> 
                    <asp:LinkButton ID="lnkGoAdvancedSearch" runat="server" Text="(search)" /> 
                    <asp:LinkButton ID="lnkHideAdvancedSearch0" runat="server" CausesValidation="false" 
                        Text="(close)" /> 
                </td> 
            </tr> 
        </table> 
    </asp:Panel> 
    <telerik:RadGrid runat="server" ID="gvResults" AllowPaging="True" AllowSorting="True" 
        AutoGenerateColumns="False" GridLines="None"> 
        <MasterTableView runat="server" PageSize="50" AllowMultiColumnSorting="true"> 
            <Columns> 
                <telerik:GridTemplateColumn HeaderText="Order No." SortExpression="SalesOrderNo"> 
                    <ItemStyle Width="60px"></ItemStyle> 
                    <ItemTemplate> 
                        <asp:HyperLink ID="hlkSalesOrderID" runat="server" CausesValidation="false" NavigateUrl='<%# "~/SearchSalesOrders.aspx?SalesOrderID=" & Eval("SalesOrderID") %>' 
                            Text='<%# Eval("SalesOrderNo") %>' /> 
                    </ItemTemplate> 
                    <ItemStyle Width="60px" HorizontalAlign="Center" /> 
                </telerik:GridTemplateColumn> 
            </Columns> 
        </MasterTableView> 
    </telerik:RadGrid> 
    <telerik:RadAjaxManager ID="ramSearchSO" runat="server" UpdatePanelsRenderMode="Inline"> 
        <AjaxSettings> 
            <telerik:AjaxSetting AjaxControlID="lnkShowAdvancedSearch"> 
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="pnlSearchCriteria" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
            <telerik:AjaxSetting AjaxControlID="pnlSearchCriteria"> 
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="gvResults" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
            <telerik:AjaxSetting AjaxControlID="lnkGoAdvancedSearch"> 
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="gvResults" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
            <telerik:AjaxSetting AjaxControlID="lnkHideAdvancedSearch"> 
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="lnkShowAdvancedSearch" /> 
                    <telerik:AjaxUpdatedControl ControlID="pnlSearchCriteria" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
        </AjaxSettings> 
    </telerik:RadAjaxManager> 
</asp:Content> 
 


 
    Private Sub lnkShowAdvancedSearch_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles lnkShowAdvancedSearch.Click 
        pnlSearchCriteria.Visible = True 
        lnkShowAdvancedSearch.Enabled = False         
    End Sub 
 
    Protected Sub lnkHideAdvancedSearch_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles lnkHideAdvancedSearch0.Click 
        lnkShowAdvancedSearch.Enabled = True 
        pnlSearchCriteria.Visible = False 
    End Sub 

please help. thanks
Veli
Telerik team
 answered on 20 Jan 2010
1 answer
163 views
Hello good people,

Telerik Chart works locally and fails on server.

Localhost page displays the chart with info from database. Server returns this:

Parser Error Message: Could not load file or assembly 'Telerik.Charting, Version=2.0.1.0, Culture=neutral, PublicKeyToken=d14f3dcc8e3e8763' or one of its dependencies. The system cannot find the file specified.

I added the charting dll as a reference and manually found it and added it to the bin folder (after adding it as a reference seemed to do nothing). Both times I uploaded it to the server. It still doesn't play nice.

I do not have a References folder where I can update the Copy Local property (as mentioned in another thread on deploying reporting). I could not find anything on deploying charting (this grid?).

- - - UPDATE

RE: http://blogs.telerik.com/blogs/posts/08-08-29/visual_studio_2008_intellisense_and_telerik_charting.aspx

Seems from this, and other things I've read, that I need to have the Ajax RadControls installed on the Server somehow. Is this true? I thought the purpose of Telerik controls is that they went with the web applicaiton and worked independent of the server.

I'm also misunderstanding MANY notes about the GAC and whether or not this DLL needs to be part of it or if it can stand alone in the BIN folder of this web app. How do I add this to the GAC? If I add it to the GAC, will it solve this problem?

- - - UPDATE 2

RE:
http://www.telerik.com/community/forums/aspnet-ajax/general-discussions/prometheus-v2-charting-dll-dependency.aspx
http://blogs.telerik.com/blogs/posts/08-08-29/visual_studio_2008_intellisense_and_telerik_charting.aspx
http://dotnetslackers.com/ASP_NET/re-133018_Visual_Studio_2008_Intellisense_and_Telerik_Charting.aspx

If I remove (comment out) the reference from the web.config, I get new errors on the server, encouraging me to remove the reference to the informix database and the using statement for the informix database until both the local and server copies fail to work.

Nice.

Thank you for your help.

Ves
Telerik team
 answered on 20 Jan 2010
1 answer
113 views
Hi,

I'm using a radprompt where the cancel button is appearing as a link button. I need the cancel button to have the normal button appearance and similarly the cancel button is apearing as a text but does not have the button functionality. Are we missing some skin or something. Pls help me with code samples.
Shinu
Top achievements
Rank 2
 answered on 20 Jan 2010
1 answer
131 views

I have a datagrid with a quantity column that's updatable on all rows. Each rows is "e.Item.Edit = true;" I use ItemCommand's UpdateAll to get the updated quantity when the user edits those quantity rows. However, they have to click "refresh cart" button to get the update going to execute the ItemCommand. I would like the review button to execute an update of the Cart prior to moving to the next page. When I try to manually trigger the itemCommand w/ "UpdateAll" I get an error because I can't completely emulate the event

I have a datagrid with a quantity column that's updatable on all rows. Each rows is "e.Item.Edit = true;" I use ItemCommand's UpdateAll to get the updated quantity when the user edits those quantity rows. However, they have to click "refresh cart" button to get the update going to execute the ItemCommand. I would like the review button to execute an update of the Cart prior to moving to the next page. When I try to manually trigger the itemCommand w/ "UpdateAll" I get an error because I can't completely emulate the event

grdOrderCart_ItemCommand(object source, GridCommandEventArgs e)

{

case "UpdateAll":

//this.UpdateOrderHeaderFields();

 

//Update Cart

 

DataRow dr;

foreach (GridEditableItem editedItem in grdOrderCart.EditItems)

{

Hashtable newValues = new Hashtable();

//The GridTableView will fill the values from all editable columns in the hash

 

e.Item.OwnerTableView.ExtractValuesFromItem(newValues, editedItem);

//skip just added items.

 

if (newValues["Quantity"] != null)

{

if (dt.Rows.Find(editedItem.GetDataKeyValue("ItemNo")) != null)

{

dr = dt.Rows.Find(editedItem.GetDataKeyValue("ItemNo"));

dr["Quantity"] = newValues["Quantity"];

dr.AcceptChanges();

}

}

}

}

 

 

 

grdOrderCart_ItemCommand(object source, GridCommandEventArgs e)

{

I have a datagrid with a quantity column that's updatable on all rows. Each rows is "e.Item.Edit = true;" I use ItemCommand's UpdateAll to get the updated quantity when the user edits those quantity rows. However, they have to click "refresh cart" button to get the update going to execute the ItemCommand. I would like the review button to execute an update of the Cart prior to moving to the next page. When I try to manually trigger the itemCommand w/ "UpdateAll" I get an error because I can't completely emulate the event

 

 

//Force Grid into EDIT mode.

 

 

 

 

 

CommandEventArgs eee = new CommandEventArgs("UpdateAll", "Hello");

 

 

GridCommandEventArgs ee = new GridCommandEventArgs(null, "UpdateAll", eee);

 

grdOrderCart_ItemCommand(grdOrderCart, ee);

grdOrderCart.Rebind();

 

 

 

 

protected void grdOrderCart_ItemCommand(object source, GridCommandEventArgs e)

 

{

 

DataTable dt = dsDSD.Tables[B2B.DSD.Tables.OrderCart];

 

dt.PrimaryKey =

new DataColumn[] { dt.Columns["ItemNo"] };

 

 

switch (e.CommandName)

 

{

 

case "Delete":

 

 

string itemNo = e.Item.OwnerTableView.DataKeyValues[e.Item.ItemIndex]["ItemNo"].ToString();

 

 

string desc = e.Item.OwnerTableView.DataKeyValues[e.Item.ItemIndex]["Description"].ToString();

 

 

if (dt.Rows.Find(itemNo) != null)

 

{

dt.Rows.Find(itemNo).Delete();

lblMessages.Text +=

string.Format("<br>Deleted: {0} - {1}", itemNo, desc);

 

dt.AcceptChanges();

}

 

break;

 

 

case "UpdateAll":

 

 

//this.UpdateOrderHeaderFields();

 

 

 

 

 

//Update Cart

 

 

 

 

 

DataRow dr;

 

 

foreach (GridEditableItem editedItem in grdOrderCart.EditItems)

 

{

 

Hashtable newValues = new Hashtable();

 

 

//The GridTableView will fill the values from all editable columns in the hash

 

 

 

 

e.Item.OwnerTableView.ExtractValuesFromItem(newValues, editedItem);

 

//skip just added items.

 

 

 

 

 

if (newValues["Quantity"] != null)

 

{

 

if (dt.Rows.Find(editedItem.GetDataKeyValue("ItemNo")) != null)

 

{

dr = dt.Rows.Find(editedItem.GetDataKeyValue(

"ItemNo"));

 

dr[

"Quantity"] = newValues["Quantity"];

 

dr.AcceptChanges();

}

}

Shinu
Top achievements
Rank 2
 answered on 20 Jan 2010
3 answers
194 views
We are using HTML to PDF converter (from Winnovative) to convert a page that has Telerik's line chart on it. All the other content on the page converts well. The chart does not convert.  Instead, the missing image (red x) appears. Has anyone seen this in the past? Did anyone find a way to get the chartimage.axd to render so we can get the chart source in the rendered page?
Ves
Telerik team
 answered on 20 Jan 2010
3 answers
173 views

Hello
I am using RadDatePicker  in my aspx page  

 

<table style="width:100%;">   
<tr> <td>   
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">   
<Scripts>   
<asp:ScriptReference Path="~/App_Javascript/DatePickerClient.js" />   
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />   
 
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />   
   
</Scripts>   
   
</telerik:RadScriptManager>   
 
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">    
 
</telerik:RadAjaxManager>   
</td> </tr> <tr> <td>   
<asp:RadioButtonList ID="Rbl" runat="server" RepeatDirection="Horizontal">   
<asp:ListItem Value="Y">Yes</asp:ListItem>   
<asp:ListItem Value="N">No</asp:ListItem>   
</asp:RadioButtonList>    
</td> </tr>    
<tr> <td>   
<telerik:RadDatePicker ID="RadDatePicker1" Runat="server">   
</telerik:RadDatePicker>   
</td> </tr>   
</table> 

DatePickerClient.js contain a function

 

function EnableDisable() {   
var rblIsGranted = document.getElementById(arguments[1]);   
var opts = rblIsGranted.getElementsByTagName("input");   
var StartDatePicker = $find(arguments[0]);   
if (opts[0].checked) {   
StartDatePicker.set_enabled(true);   
}  
else {    
StartDatePicker.set_enabled(false);   
}  
}  
 
 
 

 

and in code behind I hoodedup the onclick event to radiobuttonlist

Rbl.Attributes.Add(
"onclick", "EnableDisable('"+RadDatePicker1.ID+"','"+Rbl.ID+"')");

 

 

I can disable and enable the radDatePicker1 by seleting the radiobuttonlist either yes or no but the calendar is generating error on click once I disable the radDatePicker control the errorgenerated in buildin telerik javascript

 

if(h==Telerik.Web.UI.Calendar.Utils.RENDERINROWS)
{
for(var a=l;

a<f.rows.length; //error f is null

a++)

 


any solution please I am missing somthing in the setting?

 

 

 

 

Veli
Telerik team
 answered on 20 Jan 2010
2 answers
123 views
Hello Telerik Team,

I have a grid that has 3 pages.
I click the edit command on one item in the first page, the edit form opens.
I click the insert new item command , and the new item form opens, but the edit row now its not the same row I previously clicked to edit, but it is the row from the last page (page 3 in my case) which has the same relative index with the row I clicked first to edit.

For example, if i click edit on the first row, and then insert new row, the edited item will become the first row from the last page.

How can I solve this problem?

I am using as a datasource a List of objects which is bound on the NeedDataSource event.
Yavor
Telerik team
 answered on 20 Jan 2010
1 answer
344 views
Hello,

I have a RadGrid that contains a DetailTable.  In the DetailTable, I wish to add ImageButtons that can change the order of the items in the DetailTable.

What I need to be able to determine is, how many records will be in the detail table.  I need to know this so that for Rows 2 through n-1 (where n is the number of items), I can show both the "Up" and "Down" buttons, and for row n, I can just display the "Up" button. 

How can I determine the number of records that will be in the detail table?  I have tried on DetailTableDataBind, ItemDataBound, etc. and so far nothing has worked.  Any suggestions?  Perhaps I need to use DetailTableDataBind or something I have already tried, but with different code?

Thanks!
Princy
Top achievements
Rank 2
 answered on 20 Jan 2010
1 answer
129 views
Hi Guys,

I am having a problem in add gridGroupfield programatically. Here is my code:

User currentProfile = SessionObject.GetCurrentUserProfile();
GridTableView tableViewOrders = new GridTableView(AwardsGrid);
GridGroupByExpression expression = new GridGroupByExpression();
GridGroupByField gridGroupByField = new GridGroupByField();

// SelectFields values (appear in header)
gridGroupByField = new GridGroupByField();
gridGroupByField.FieldName = currentProfile.FirstName;
gridGroupByField.HeaderText = "Firstname";

expression.SelectFields.Add(gridGroupByField);
gridGroupByField = new GridGroupByField();
gridGroupByField.FieldName = currentProfile.Surname;
gridGroupByField.HeaderText = "Lastname ";
expression.SelectFields.Add(gridGroupByField);

//GroupByFields values (group data)
gridGroupByField = new GridGroupByField();
gridGroupByField.FieldName = currentProfile.FirstName;
expression.GroupByFields.Add(gridGroupByField);
tableViewOrders.GroupByExpressions.Add(expression);


 

 



Many thanks

 

 

 

Erwin Floresca
Top achievements
Rank 1
 answered on 20 Jan 2010
2 answers
132 views
Hi,
  I worked two way binding in Telerik silverlight controls.Is it possible to have two way binding in Telerik Ajax controls dynamically using custom class.if so give me a small for this.

regards,
sathies
sathies
Top achievements
Rank 1
 answered on 20 Jan 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?