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

I am trying to implement radconfirm (Confirm postback with radconfirm) as described on this link
http://demos.telerik.com/aspnet-ajax/window/examples/browserdialogboxes/defaultcs.aspx

when I put LinkButton and configure, it works fine, but when I change its text like <b>LinkButton</b>, window works fine (it opens), its cancel event works fine, but its ok button does not post back, and confirm window stays visible. I use <b> tag because I am using it for slidingdoors technique and css.
Here is generated html codes. First one works fine, second does not.
<onclick="return blockConfirm('Are you sure you want to delete this record?', event, 250, 100,'','Confirm Delete');" id="LinkButton1" href="javascript:__doPostBack('LinkButton1','')">LinkButton</a> 
 
<onclick="return blockConfirm('Are you sure you want to delete this record?', event, 250, 100,'','Confirm Delete');" id="LinkButton1" href="javascript:__doPostBack('MOB1','')"><b>LinkButton</b></a


Any thoughts?

Thanks in advance.
Barbaros Saglamtimur
Top achievements
Rank 1
 answered on 18 May 2009
0 answers
216 views
Hi,
i'm using RadTreeView like menu on MasterPage. in code:

 

protected void RadTreeMenu_DataBound(object sender, EventArgs e)

 

{

 

// add url to Nodes

 

 

foreach (RadTreeNode node in RadTreeMenu.GetAllNodes())

 

{

node.NavigateUrl =

"ProductList.aspx?color=" + node.Value ;

 

}

}


I set NavigateUrl for each node but when I try get data from Request.Querystring["color"] (in pageLoad ProductList.aspx)
I can to do only when I load page first time, from difrent page. When I'm on ProductList.aspx and click in tree node commends in PageLoad are not runing.

How I can take value from valiable "color"?
Regards.
Leszek
Leszek
Top achievements
Rank 1
 asked on 18 May 2009
4 answers
244 views
Has anyone found a way to assign the resource styles in a database table and then call them through code?  I have two identical calendars(User and Admin) and thought it's redundant to hard code resource styles in both calendars.

Here's an initial attempt i tried so far.  I figured if this worked then I could code a loop to read this info from a db.  But it didn't work.

RadScheduler1.ResourceStyles.Clear() 
RadScheduler1.ResourceStyles.Add(New Telerik.Web.UI.ResourceStyleMapping("EventType""Class""rsCategoryDarkBlue")) 

Oh, and that's in the Page_Load event.  It successfully cleared all the styles, but didn't replace with the new syle assignment.  Where/when would I need to call this?  Or is there another way to do this altogether?
Matt
Top achievements
Rank 1
 answered on 18 May 2009
1 answer
144 views
Hi, I have a ComboBox inside a RadGrid ItemTemplate with EnableLoadOnDemand set to true, and I can't retrieve the selected value on postback:

<telerik:GridTemplateColumn HeaderText="New Status" UniqueName="Status" AllowFiltering="False">  
                        <ItemTemplate>  
                                 <telerik:RadComboBox runat="Server" ID="rcbNewStatus"  
                                        Width="300px"  
                                        MarkFirstMatch = "True"  
                                        DataSourceID ="sqlStatusList"  
                                        EnableLoadOnDemand = "True"  
                                        HighlightTemplatedItems = "True"  
                                        OnClientItemsRequested="UpdateItemCountField"  
                                        OnItemDataBound="rcbStatus_ItemDataBound"  
                                        OnDataBound = "rcbStatus_DataBound"  
                                        OnItemsRequested="rcbStatus_ItemsRequested"  
                                      EnableViewState ="True"  
                                        >  
                                        <HeaderTemplate>  
                                            <ul>  
                                                 <li class="col1">Status Code</li>  
                                                 <li class="col2">Status Description</li>  
                                            </ul>  
                                         </HeaderTemplate>  
                                         <ItemTemplate>  
                                            <ul>  
                                                <li class="col1"><%# DataBinder.Eval(Container.DataItem, "StatusCode") %></li>  
                                                <li class="col2"><%# DataBinder.Eval(Container.DataItem, "StatusDesc") %></li>  
                                            </ul>          
                                         </ItemTemplate>  
                                         <FooterTemplate>  
                                            A Total of <asp:Literal runat="server" ID="rcbItemsCount" /> items              
                                         </FooterTemplate>  
</telerik:RadComboBox>  

Everything works perfectly, each comboBox in the Grid loads the right data, etc.  The only problem is that if I try to access the selected value server-side, I get an empty string.  This is how I'm trying to access the value, I iterate through the GridItems of the RadGrid, and I can see the ComboBox object and its properties, but the content don't seem to persist and neither does the selected value:

If TypeOf (oControl) Is RadComboBox Then  
       sStatus = CType(oControl, RadComboBox).SelectedValue  
End If  

Am I missing something?

Thank you.



Condorito
Top achievements
Rank 1
 answered on 18 May 2009
2 answers
158 views
Hi,

I could not find a way to change the background color of the RadComboBox item when mouse is hovered on it.

I am using the WebBlue skin, but I need to change the hovered RadComboBox item color from the default one.

Thank You,
Siva
Siva
Top achievements
Rank 1
 answered on 18 May 2009
0 answers
88 views
I have a hierarchical treeview in a formview.  Is is possible to data bind to the treeview (two-way)?

ex:

               
                <telerik:RadTreeView ID="rtvCategories" runat="server" 
                    DataSourceID="ldsCategories"  
                    DataFieldID="ID" DataFieldParentID="ParentID" 
                    DataTextField="Name" DataValueField="ID" 
                    SelectedValue='<% Bind("CategoryID") %>'
                </telerik:RadTreeView> 
                <asp:LinqDataSource ID="ldsCategories" runat="server"  
                    ContextTypeName="DataAccess.DataContext" TableName="Categories" > 
                </asp:LinqDataSource>       

I know you can't do it the way I do it above since "SelectedValue" is readonly.  Is there a work around?
Justin
Top achievements
Rank 1
 asked on 18 May 2009
3 answers
141 views
Hi 

I have a number of checkboxes within a radpanelitem each one loads a different set of data.
I have enabled the radcalendar to show if there is anything going on on that day by makling the day show in bold. the problem is, that when i check or uncheck any of these boxes that data changes , which is correct, but i cant get the radcalendar to refresha at the same time, this  causing the calendar formatting to be incorrect as it may show that there is still something happening on that day , when i have jclearly ust unchecked the item to remove that data from the scheduler.

Is there a way to refresh this calendar when checking or unchecking?

Thanks
T. Tsonev
Telerik team
 answered on 18 May 2009
1 answer
159 views
I am using example from this page:--
http://demos.telerik.com/aspnet-ajax/grid/examples/hierarchy/nestedviewtemplate/defaultcs.aspx



How to access controls of a "DetailsView1" dug deep inside many levels in a RadGrid? I am using objectDataSource in server side, and when I fire up "OnItemUpdating="DetailsView1_ItemUpdating"", what code should I write in OnItemUpdating so that I can grab the values typed by the user and pass these values for the update. I need to perform this Update task from.cs file NOT .aspx.

The page structure is like this:

<telerik:RadGrid ID="RadGrid1"
    <MasterTableView
        <NestedViewTemplate>
            <asp:Panel
                <telerik:RadTabStrip></telerik:RadTabStrip>
                <telerik:RadMultiPage ID="Multipage1"
                    <telerik:RadPageView ID="PageView1"
                        <asp:DetailsView ID="DetailsView1" OnItemUpdating="DetailsView1_ItemUpdating"
                            <Fields>
                                <asp:TemplateField>
                                    <ItemTemplate></ItemTemplate>
                                    <EditItemTemplate></EditItemTemplate>
                                 </asp:TemplateField>   





Here is my code:--------------------

<telerik:RadGrid ID="RadGrid1" runat="server" DataSourceID="ObjUserDetail_GetAllUsers" Width="1178px"
    Skin="Office2007" AutoGenerateColumns="False" AllowSorting="True" AllowMultiRowSelection="False"
    AllowPaging="True" PageSize="5" GridLines="None" ShowGroupPanel="true" OnItemCreated="RadGrid1_ItemCreated"
    OnItemCommand="RadGrid1_ItemCommand">
    <MasterTableView DataSourceID="ObjUserDetail_GetAllUsers" DataKeyNames="UserName" AllowMultiColumnSorting="True" GroupLoadMode="Server">
        <NestedViewTemplate>
            <asp:Panel runat="server" ID="InnerContainer" CssClass="NestedGridTemplate" Visible="false">
                <telerik:RadTabStrip runat="server" ID="TabStip1" MultiPageID="Multipage1" Skin="Office2007" SelectedIndex="0">
                    <Tabs>
                        <telerik:RadTab runat="server" Text="User Details" PageViewID="PageView1"></telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Hospital Assign" PageViewID="PageView2"></telerik:RadTab>
                        <telerik:RadTab runat="server" Text="Survey Contact" PageViewID="PageView3"></telerik:RadTab>
                    </Tabs>
                </telerik:RadTabStrip>
                <telerik:RadMultiPage runat="server" ID="Multipage1" SelectedIndex="0" RenderSelectedPageOnly="false">
                    <telerik:RadPageView runat="server" ID="PageView1" CssClass="blueBox2">
                        <asp:Label ID="Label1" Font-Bold="true" Font-Italic="true" Text='<%# Eval("UserName") %>' Visible="false" runat="server" />
                        <table cellpadding="0" cellspacing="0">
                            <tr><td colspan="2">&nbsp;</td></tr>
                            <tr>
                                <td width="25px">&nbsp;</td>
                                <td>
                                    <asp:DetailsView OnItemUpdating="DetailsView1_ItemUpdating" ID="DetailsView1" DataKeyNames="UserName" AllowPaging="true" GridLines="None" Width="100%"
                                        DataSourceID="ObjUserDetail_GetUserDetailsByUserName" OnItemUpdated="DetailsView1_ItemUpdated" runat="server" AutoGenerateRows="false">
                                        <Fields>
                                            <asp:TemplateField>
                                                <ItemTemplate>                                               
                                                    <table cellpadding="4px" cellspacing="0px" width="100%" border="0px">
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label1" runat="server" Text="Username:"></asp:Label></td>
                                                            <td><asp:Label ID="LblUserName" runat="server" Text='<%# Eval("UserName") %>'></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label2" runat="server" Text="First Name:"></asp:Label></td>
                                                            <td><asp:Label ID="LblFirstName" runat="server" Text='<%# Eval("FirstName") %>'></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label3" runat="server" Text="Last Name:"></asp:Label></td>
                                                            <td><asp:Label ID="LblLastName" runat="server" Text='<%# Eval("LastName") %>'></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label4" runat="server" Text="Email:"></asp:Label></td>
                                                            <td><asp:Label ID="LblEmail" runat="server" Text='<%# Eval("Email") %>'></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label5" runat="server" Text="Title:"></asp:Label></td>
                                                            <td><asp:Label ID="LblTitle" runat="server" Text='<%# Eval("Title") %>'></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label6" runat="server" Text="Phone:"></asp:Label></td>
                                                            <td><asp:Label ID="LblPhone" runat="server" Text='<%# Eval("Phone") %>'></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label7" runat="server" Text="Phone Ext.:"></asp:Label></td>
                                                            <td><asp:Label ID="LblPhoneExt" runat="server" Text='<%# Eval("PhoneExt") %>'></asp:Label>&nbsp;</td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label8" runat="server" Text="Fax:"></asp:Label></td>
                                                            <td><asp:Label ID="LblFax" runat="server" Text='<%# Eval("Fax") %>'></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label9" runat="server" Text="IsApproved:"></asp:Label></td>
                                                            <td><asp:CheckBox Checked='<%# Eval("IsApproved") %>' ID="Label11" runat="server"></asp:CheckBox>&nbsp;</td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label12" runat="server" Text="IsLockedOut:"></asp:Label></td>
                                                            <td><asp:CheckBox Checked='<%# Eval("IsLockedOut") %>' ID="CheckBox1" runat="server"></asp:CheckBox></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td colspan="2">&nbsp;</td>
                                                        </tr>                                                        
                                                    </table>
                                                </ItemTemplate>
                                                <EditItemTemplate>
                                                    <table cellpadding="3px" cellspacing="0px" width="100%" border="0px">
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label1" runat="server" Text="Username:"></asp:Label></td>
                                                            <td><asp:Label ID="LblUserName" runat="server" Text='<%# Eval("UserName") %>'></asp:Label></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label2" runat="server" Text="First Name:"></asp:Label></td>
                                                            <td><asp:TextBox ID="TxtFirstName" runat="server" Text='<%# Eval("FirstName") %>'></asp:TextBox></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label3" runat="server" Text="Last Name:"></asp:Label></td>
                                                            <td><asp:TextBox ID="TxtLastName" runat="server" Text='<%# Eval("LastName") %>'></asp:TextBox></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label4" runat="server" Text="Email:"></asp:Label></td>
                                                            <td><asp:TextBox ID="TxtEmail" runat="server" Text='<%# Eval("Email") %>'></asp:TextBox></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label5" runat="server" Text="Title:"></asp:Label></td>
                                                            <td><asp:TextBox ID="TxtTitle" runat="server" Text='<%# Eval("Title") %>'></asp:TextBox></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label6" runat="server" Text="Phone:"></asp:Label></td>
                                                            <td><asp:TextBox ID="TxtPhone" runat="server" Text='<%# Eval("Phone") %>'></asp:TextBox></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label7" runat="server" Text="Phone Ext.:"></asp:Label></td>
                                                            <td><asp:TextBox ID="TxtPhoneExt" runat="server" Text='<%# Eval("PhoneExt") %>'></asp:TextBox></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label8" runat="server" Text="Fax:"></asp:Label></td>
                                                            <td><asp:TextBox ID="TxtFax" runat="server" Text='<%# Eval("Fax") %>'></asp:TextBox></td>
                                                        </tr>
                                                        <tr>
                                                            
                                                        <td><asp:CheckBox Checked='<%# Eval("IsApproved") %>' ID="ChkIsApproved" runat="server"></asp:CheckBox></td>
                                                        </tr>
                                                        <tr>
                                                            <td width="75px" align="right"><asp:Label ID="Label12" runat="server" Text="IsLockedOut:"></asp:Label></td>
                                                            <td><asp:CheckBox Checked='<%# Eval("IsLockedOut") %>' ID="ChkIsLocedOut" runat="server"></asp:CheckBox></td>
                                                        </tr>
                                                        <tr>
                                                            <td colspan="2">&nbsp;</td>
                                                        </tr>                                     
                                                    </table>                                     
                                                </EditItemTemplate>
                                            </asp:TemplateField>
                                            <asp:CommandField ShowEditButton="True" ButtonType="Image" EditImageUrl="~/images/Update.gif" UpdateImageUrl="~/images/Save.gif" CancelImageUrl="~/images/Cancel.gif" />
                                        </Fields>
                                    </asp:DetailsView>                                               
                                    <asp:ObjectDataSource ID="ObjUserDetail_GetUserDetailsByUserName" runat="server"
                                        SelectMethod="UserDetail_GetUserDetailsByUserName" TypeName="Survey.BLL.UserDetailManager">
                                        <SelectParameters>
                                            <asp:ControlParameter ControlID="Label1" PropertyName="Text" Type="String" Name="UserName" />
                                        </SelectParameters>
                                    </asp:ObjectDataSource>                                                
                                </td>
                            </tr>
                            <tr>
                                <td colspan="2">&nbsp;</td>
                            </tr>
                        </table>
                    </telerik:RadPageView>
                </telerik:RadMultiPage>
            </asp:Panel>
        </NestedViewTemplate>
        <Columns>
            <telerik:GridBoundColumn SortExpression="FirstName" HeaderText="First Name" HeaderButtonType="TextButton" DataField="FirstName" UniqueName="FirstName"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn SortExpression="LastName" HeaderText="Last Name" HeaderButtonType="TextButton"    DataField="LastName" UniqueName="LastName"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn SortExpression="Title" HeaderText="Title" HeaderButtonType="TextButton" DataField="Title" UniqueName="Title"></telerik:GridBoundColumn>
            <telerik:GridBoundColumn SortExpression="Email" HeaderText="Email" HeaderButtonType="TextButton" DataField="Email" UniqueName="Email"></telerik:GridBoundColumn>
            <telerik:GridCheckBoxColumn SortExpression="IsApproved" HeaderText="IsApproved" HeaderButtonType="TextButton" DataField="IsApproved" UniqueName="IsApproved"></telerik:GridCheckBoxColumn>
            <telerik:GridCheckBoxColumn SortExpression="IsLockedOut" HeaderText="IsLockedOut" HeaderButtonType="TextButton" DataField="IsLockedOut" UniqueName="IsLockedOut"></telerik:GridCheckBoxColumn>
        </Columns>
    </MasterTableView>
    <ClientSettings AllowDragToGroup="true" />
</telerik:RadGrid>
Sebastian
Telerik team
 answered on 18 May 2009
5 answers
145 views
Hi
I have a radajaxloading panel with a cancel button in it which has a javascript event as

function AbortAllPostbacks() {
        var prm = Sys.WebForms.PageRequestManager.getInstance();
        prm.abortPostBack();
    }

Even if I click that button to cancel ajax the request ,
page gets a whole postback after some time and I lose my dynamically created controls in radajax panels.
How can I avoid this?
Is there a way to stop server side execution?
Thanks.
Pavlina
Telerik team
 answered on 18 May 2009
3 answers
129 views
Hi

Is it possible to alter the time increments shown in the appointment views? and is it possible for them to be different?
ie
9.15 to 10.15
10.15 to 11.30

Thanks
Dimitar Milushev
Telerik team
 answered on 18 May 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?