Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
108 views
Hi Guys and Gals,

I am trying to figure out whether the RadScheduler would be ideal for our new application.Here are a few requirements that have left me scratching my head.Any help in solving them would be greatly appreciated.

1) I have a textbox to add certain notes.Once submitted it should be made read only but new notes should be added. 

2) Right-mouse clicking on any existing event from any view should allow the user to "Duplicate" that event and pre-populate the event entry form with the same values except for date/time-related fields.

3) Is it possible to display the no.of events booked on a particular date by hovering over it.

Has anybody incorporated these kind of requirements in their RadScheduler?Is it possible to customize the RadScheduler for these requirements programmatically?

Thanks in advance.
Peter
Telerik team
 answered on 02 Jul 2009
1 answer
97 views
Hi,

I have put a RadSlider as this :
<telerik:RadSlider ID="slideHeight" runat="server" LargeChange="30"  
                MaximumValue="320" MinimumValue="20" Orientation="Vertical"  
                TrackMouseWheel="False" Height="300px"  IsDirectionReversed="True" /> 

When rendered, the labels for increase/decrease handle are not swapped : top one shows "Decrease" instead of "Increase".

Can you tell me if I'm wrong please ?

Thanks.


Tsvetie
Telerik team
 answered on 02 Jul 2009
3 answers
117 views

 

Hello
Please can someone have a look at what i have done wrong below.  if i uncomment the line 'e.DetailTableView.DataBind()' it seems to go into an infinate loop and times out...if i remove that line i just get No child records to display. i have got 6 records in objMonitor that have loaded ok.

thanks so much as just cant seem to get it working.

Private
Sub radgridstats_DetailTableDataBind(ByVal source As Object, ByVal e As Telerik.Web.UI.GridDetailTableDataBindEventArgs) Handles radgridstats.DetailTableDataBind

 

 

    Dim dataItem As Telerik.Web.UI.GridDataItem = CType(e.DetailTableView.ParentItem, Telerik.Web.UI.GridDataItem)

 

 

    Select Case e.DetailTableView.Name

 

 

    Case "DivisionOne"

 

 

    Dim DemographicID As String = dataItem.GetDataKeyValue("DemographicID").ToString()

 

 

    Dim objMonitors As New Pearson.Monitors

 

    objMonitors.LoadStats(DemographicID, 1)

    e.DetailTableView.DataSource = objMonitors 

 

    'e.DetailTableView.DataBind()

 

 

 

 


End
Select

 

 

End Sub

 

Sebastian
Telerik team
 answered on 02 Jul 2009
6 answers
140 views
I am in the process of upgrading a fairly large project from the asp.net suite to the ajax suite, and have hit a rather strange bug.

I am attempting to upgrade the chart control and to test the functioanlity I am attempting to display a very simple graph from the demo's page

<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %> 
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Charting" tagprefix="telerik" %> 
 
<telerik:RadChart runat="server" Width="500px" ID="RadChart2" Skin="LightGreen" > 
     <Series> 
     <telerik:ChartSeries Name="series 1" Type="Bar">  
     <Items> 
     <telerik:ChartSeriesItem YValue="5" /> 
     <telerik:ChartSeriesItem YValue="50" /> 
     <telerik:ChartSeriesItem YValue="500" /> 
     <telerik:ChartSeriesItem YValue="5000" /> 
     </Items> 
     </telerik:ChartSeries> 
     </Series> 
     <PlotArea> 
     <Appearance> 
     </Appearance> 
            <YAxis IsLogarithmic="true">  
            </YAxis> 
     </PlotArea> 
        <ChartTitle> 
            <TextBlock Text="Logarithmic Axis">  
                <Appearance TextProperties-Color="70, 143, 190">  
                </Appearance> 
            </TextBlock> 
        </ChartTitle> 
</telerik:RadChart> 

The problem is when I try to display this in a ascx file I get the 'Error loading radchart image' message box... The strange thing is that when I copy the above code to an aspx file on the same site it works perfectly - which I guess indicates that the configuration is OK.  I have tired switching the DNN 'Supports Partial Rendering?' flag to no avail.

For the moment I will revert to the asp.net control, but if you can help it would be appreciated as I would prefer to only use one suite if possible.

Suite version : Q1 2009
DNN version : 4.6.2
Alex Lawson
Top achievements
Rank 1
 answered on 02 Jul 2009
2 answers
120 views

Hi,

I have a GridButtonColumn in my RadGrid which is a delete button for a tag and executes the deletecommand defined in my datasource. This delete actually deletes the pair "contentID" and "tagID" from my table tagsContents. However, as well as the delete of this pair from my table tagsContents, I also want to execute an update of my table tags where I decrease the count column of that tag by 1. This means that as I delete the pair tag - content, I also must decrease the count in the tags table. How can I execute this update command when I click the delete button? Can I associate both commands to the action of clicking the button? Here is my code:

This is the GridButtonColumn:

<telerik:GridButtonColumn ConfirmText="Tem a certeza de que pretende apagar esta tag deste conteúdo?" ConfirmDialogType="RadWindow" ConfirmTitle="Apagar" ButtonType="ImageButton" ButtonCssClass="pointer" CommandName="Delete" Text="Apagar" ItemStyle-Width="10%" UniqueName="ApagarTag" ImageUrl="~/imagens/bt_scorm_falhou.gif" ItemStyle-HorizontalAlign="Center" />

This is the datasource:

<asp:SqlDataSource ID="GET_TAGS_CONT" runat="server" ConnectionString="<%$ ConnectionStrings:lms_bibliotecaConnectionString1 %>"
                      SelectCommand="SELECT * FROM NL_LMS_BIB_tags INNER JOIN NL_LMS_BIB_tagsConteudos ON NL_LMS_BIB_tags.IDTag=NL_LMS_BIB_tagsConteudos.IDTag AND NL_LMS_BIB_tagsConteudos.IDConteudo = @idconteudo"
                      DeleteCommand="DELETE FROM [NL_LMS_BIB_tagsConteudos] WHERE IDTag = @IDTag AND IDConteudo=@idconteudo" >
    <SelectParameters>
        <asp:SessionParameter Name="idconteudo" SessionField="idconteudo" />
    </SelectParameters>
    <DeleteParameters>
        <asp:SessionParameter Name="idconteudo" SessionField="idconteudo" />
        <asp:Parameter Name="IDTag" />
    </DeleteParameters>
</asp:SqlDataSource>

Thanks!
Marta

Marta
Top achievements
Rank 1
 answered on 02 Jul 2009
0 answers
97 views
Dear reader,

I'm having trouble setting the focus on a radtreeview after doing a serverside action.

The function of this page:
Someone searches a phrase and presses "zoek". Grid gvZoeken gets filled with the results.
Clicking the linkbutton in the grid filles the plnTeksten with the desired text and the desired node in the tree gets selected (abusing the linkbuttons CommandArgument for that.). I also want the page to be scrolled to the treeview thats below the searchgrid.

Things that didnt work:
* RadAjaxManager1.FocusControl(RadTreeView1.ClientID)

* Setting focus on a node in serverside code (RadTreeView1.FindNodeByValue(lb.CommandArgument).Focus())
* Registering a clientscript in the RadScriptManager 
* removing the formdecorator
* All kinds of examples in this forum and the on-line help.

What does work, but is not the desired solution:
Putting a visible textbox on the page and focusing it with RadAjaxManager1.FocusControl(Textbox1.ClientID)

Anyone got idea's?

ASPX:
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Dossier.aspx.vb" Inherits="Dossiers_Dossier" %> 
 
<%@ Register Assembly="Telerik.Web.UI, Version=2009.1.527.20, Culture=neutral, PublicKeyToken=121fae78165ba3d4" 
    Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml">  
<head runat="server">  
    <title>Dossier</title> 
    <link href="../css/StyleSheet.css" rel="stylesheet" type="text/css" /> 
</head> 
<body> 
    <form id="form1" runat="server">  
    <div> 
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server">  
        </telerik:RadScriptManager> 
        <telerik:RadFormDecorator ID="RadFormDecorator1" runat="server" Skin="Sunset" /> 
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">  
            <AjaxSettings> 
                <telerik:AjaxSetting AjaxControlID="RadTreeView1">  
                    <UpdatedControls> 
                        <telerik:AjaxUpdatedControl ControlID="RadTreeView1" /> 
                        <telerik:AjaxUpdatedControl ControlID="pnlTeksten" /> 
                        <telerik:AjaxUpdatedControl ControlID="pnlDossier" /> 
                    </UpdatedControls> 
                </telerik:AjaxSetting> 
                <telerik:AjaxSetting AjaxControlID="gvZoeken">  
                    <UpdatedControls> 
                        <telerik:AjaxUpdatedControl ControlID="RadTreeView1" /> 
                        <telerik:AjaxUpdatedControl ControlID="pnlTeksten" /> 
                        <telerik:AjaxUpdatedControl ControlID="pnlDossier" /> 
                     </UpdatedControls> 
                </telerik:AjaxSetting> 
            </AjaxSettings> 
        </telerik:RadAjaxManager> 
        <table> 
            <tr> 
                <td> 
                    <telerik:RadMenu ID="RadMenu1" runat="server" Skin="Sunset">  
                        <Items> 
                            <telerik:RadMenuItem Text="Terug" NavigateUrl="Default.aspx" /> 
                        </Items> 
                    </telerik:RadMenu> 
                </td> 
                <td> 
                    <h1> 
                        <asp:Label ID="lblTitel" runat="server"></asp:Label></h1>  
                </td> 
            </tr> 
            <tr> 
                <td colspan='2'>  
                    <table> 
                        <tr> 
                            <td> 
                                Zoek in dossier:  
                            </td> 
                            <td> 
                                <asp:TextBox ID="tbZoekterm" runat="server"></asp:TextBox><asp:Button ID="butZoek" 
                                    runat="server" Text="Zoek" /><br /> 
                                <asp:Label ID="lblEror" runat="server" ForeColor="Red"></asp:Label> 
                            </td> 
                        </tr> 
                        <tr> 
                            <td> 
                                &nbsp;  
                            </td> 
                            <td> 
                                <telerik:RadGrid ID="gvZoeken" runat="server" AllowPaging="True" AllowSorting="True" 
                                    AutoGenerateColumns="False" GridLines="None" Skin="Sunset" DataSourceID="SqlDataSource2">  
                                    <PagerStyle Mode="NextPrevAndNumeric" NextPageToolTip="Volgende pagina" PagerTextFormat="Verander pagina: {4} &amp;nbsp;Getoonde pagina {0} van {1}, rijen {2} t/m {3} van {5}." 
                                        PrevPageToolTip="Vorige pagina" FirstPageToolTip="Eerste pagina" LastPageToolTip="Laatste pagina" /> 
                                    <MasterTableView DataKeyNames="TekstNr" NoMasterRecordsText="Geen resultaten gevonden." 
                                        DataSourceID="SqlDataSource2" PageSize="10">  
                                        <Columns> 
                                            <telerik:GridTemplateColumn> 
                                                <ItemTemplate> 
                                                    <asp:LinkButton ID="LinkButton1" runat="server" Text='<%# Highlight(tbZoekterm.Text,Eval("Titel")) %>' 
                                                        CommandArgument='<%# Eval("TekstNr") %>' OnClick="ZoekItemClick">LinkButton</asp:LinkButton> 
                                                    <br /> 
                                                    <br /> 
                                                    <asp:Literal ID="Literal1" runat="server" Text='<%# Highlight(tbZoekterm.Text,Eval("tekst"))%>'></asp:Literal> 
                                                </ItemTemplate> 
                                            </telerik:GridTemplateColumn> 
                                        </Columns> 
                                    </MasterTableView> 
                                    <ClientSettings EnableRowHoverStyle="true" /> 
                                    <SortingSettings SortedAscToolTip="Oplopend gesoteerd" SortedDescToolTip="Aflopend gesorteerd" 
                                        SortToolTip="Klik hier om te sorteren" /> 
                                </telerik:RadGrid> 
                                <asp:SqlDataSource ID="SqlDataSource2" ConnectionString="<%$ ConnectionStrings:DB %>" 
                                    ProviderName="System.Data.SqlClient" SelectCommand="Zoek_in_dossier" SelectCommandType="StoredProcedure" 
                                    runat="server">  
                                    <SelectParameters> 
                                        <asp:QueryStringParameter Name="dossiernr" QueryStringField="dId" Type="Int32" /> 
                                        <asp:FormParameter Name="Zoekterm" FormField="tbZoekterm" Type="String" /> 
                                    </SelectParameters> 
                                </asp:SqlDataSource> 
                            </td> 
                        </tr> 
                    </table> 
                </td> 
            </tr> 
            <tr> 
                <td valign="top">  
                    <telerik:RadTreeView ID="RadTreeView1" runat="server" Skin="Sunset" EnableDragAndDrop="False" 
                        EnableDragAndDropBetweenNodes="False" AllowNodeEditing="False" DataFieldID="Tekstnr" 
                        DataFieldParentID="ParentID" DataSourceID="SqlDataSource1" DataTextField="Titel" 
                        DataValueField="Tekstnr">  
                    </telerik:RadTreeView> 
                    <asp:SqlDataSource ID="SqlDataSource1" ConnectionString="<%$ ConnectionStrings:DB %>" 
                        ProviderName="System.Data.SqlClient" SelectCommand="GET_DOSSIER_TEKSTEN" SelectCommandType="StoredProcedure" 
                        runat="server">  
                        <SelectParameters> 
                            <asp:QueryStringParameter Name="dossiernr" QueryStringField="dId" Type="Int32" /> 
                        </SelectParameters> 
                    </asp:SqlDataSource> 
                </td> 
                <td valign="top">  
                    <asp:Panel ID="pnlDossier" runat="server">  
                        <table> 
                            <tr> 
                                <td> 
                                    Dossier titel:  
                                </td> 
                                <td> 
                                    <asp:Label ID="lblDossierTitel" runat="server"></asp:Label> 
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    Instituut:  
                                </td> 
                                <td> 
                                    <asp:Label ID="lblInstituut" runat="server"></asp:Label> 
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    Versie:  
                                </td> 
                                <td> 
                                    <asp:Label ID="lblVersie" runat="server"></asp:Label> 
                                </td> 
                            </tr> 
                        </table> 
                    </asp:Panel> 
                    <asp:Panel ID="pnlTeksten" runat="server" Visible="false">  
                        <table> 
                            <tr> 
                                <td> 
                                    &nbsp;  
                                </td> 
                                <td> 
                                 
                                    <asp:Label ID="lblTitel2" runat="server"></asp:Label> 
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    &nbsp;  
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    &nbsp;  
                                </td> 
                                <td> 
                                    Samenvatting:<br /> 
                                    <asp:Label ID="lblSamenvatting" runat="server" /> 
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    &nbsp;  
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    &nbsp;  
                                </td> 
                                <td> 
                                    Verdieping:<br /> 
                                    <asp:Label ID="lblVerdieping" runat="server" /> 
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    &nbsp;  
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    &nbsp;  
                                </td> 
                                <td> 
                                    Detaillering:<br /> 
                                    <asp:Label ID="lblDetaillering" runat="server" /> 
                                </td> 
                            </tr> 
                            <tr> 
                                <td> 
                                    &nbsp;  
                                </td> 
                            </tr> 
                        </table> 
                    </asp:Panel> 
                </td> 
            </tr> 
        </table> 
    </div> 
    </form> 
</body> 
</html> 
 
VB
Imports Telerik.Web.UI  
Partial Class Dossiers_Dossier  
    Inherits System.Web.UI.Page  
 
    Dim dossierID As Integer 
 
    Protected Sub Page_Load(ByVal sender As ObjectByVal e As System.EventArgs) Handles Me.Load  
        dossierID = Request("did")  
 
    End Sub 
 
    Protected Sub RadTreeView1_NodeDataBound(ByVal sender As ObjectByVal e As Telerik.Web.UI.RadTreeNodeEventArgs) Handles RadTreeView1.NodeDataBound  
        'Expand the parent  
        If e.Node.Value = "0" Then 
            e.Node.Expanded = True 
        End If 
    End Sub 
 
    Protected Sub RadTreeView1_NodeClick(ByVal sender As ObjectByVal e As Telerik.Web.UI.RadTreeNodeEventArgs) Handles RadTreeView1.NodeClick  
        'Selected node changed  
        NodeSelectieveranderd(e.Node)  
    End Sub 
 
    Sub NodeSelectieveranderd(ByVal n As RadTreeNode)  
        If n.Value = "0" Then 'new selectednode is rootnode  
            pnlDossier.Visible = True 
            pnlTeksten.Visible = False 
            lblTitel2.Text = "" 
            lblSamenvatting.Text = "" 
            lblVerdieping.Text = "" 
            lblDetaillering.Text = "" 
        Else 'childnode  
            pnlDossier.Visible = False 
            pnlTeksten.Visible = True 
 
  'fill pnlTeksten  
lblTitel2.Text = "test" 
            n.ExpandParentNodes()  
        End If 
 
    End Sub 
 
    'Find and highlight words that match the searchvalue  
    Public Function Highlight(ByVal Search_Str As StringByVal InputTxt As StringAs String 
        ' Setup the regular expression and add the Or operator.     
        Dim RegExp As New Regex(Search_Str.Replace(" ""|").Trim(), RegexOptions.IgnoreCase)  
        ' Highlight keywords by calling the delegate each time a keyword is found.     
        Return RegExp.Replace(InputTxt, New MatchEvaluator(AddressOf ReplaceKeyWords))  
        ' Set the RegExp to null.     
    End Function 
 
    'Highlight the keywords  
    Public Function ReplaceKeyWords(ByVal m As Match) As String 
        Return "<span class='Highlight'>" + m.Value + "</span>" 
    End Function 
 
    'Linkbutton in searchgrid is clicked  
    Protected Sub ZoekItemClick(ByVal sender As ObjectByVal e As System.EventArgs)  
        Dim lb As LinkButton = CType(sender, LinkButton)  
        RadTreeView1.FindNodeByValue(lb.CommandArgument).Selected = True 
        NodeSelectieveranderd(RadTreeView1.SelectedNode)  
        RadAjaxManager1.FocusControl(RadTreeView1.ClientID)  
    End Sub 
 
End Class 
it-workz
Top achievements
Rank 1
 asked on 02 Jul 2009
2 answers
107 views
Hi i use telerik rad asp.net controls in my projects(radcombo,radnumerictxtbox e.g.)
I have to clear the all inputs in client-side with javascript

how to do that for radcontrols?
thnx
dank
Top achievements
Rank 1
 answered on 02 Jul 2009
1 answer
109 views
Hi,

 We have a requirement where a TreeViewNode text should have different colors. For ex: if the text is "AAA: Generate Profile" then "AAA" shuld be in red color and "Generate Profile" should be in blue.
 Another requirement is that of having a drill down popup for a Treeview node.

So please let us know if the Telerik's TreeView control can meet these 2 requirements?.

Thanks,
Abhishek
Paul
Telerik team
 answered on 02 Jul 2009
1 answer
174 views

Hi Support Team,

I am working on Rad Editor. In the image upload Area. Afterbrowsing the image I have to add below code inthe click event of upload button.

WebClient oclient = new WebClient();

byte[] responseArray = oclient.UploadFile(PageUrlofRemoteServer,"POST",UploadimagePathAlongwithFileName);

Reason :

 I have to upload thebrowse image to some other location (other domain like http://www.domain.com/images/imagefilename)

for that I wrote the above code which work fine.

But how can integrate this code with Rad Editor UploadButton Click event.

Regards

Ravindra Sahasrabudhe

(rs@mtccrm.com)

Lini
Telerik team
 answered on 02 Jul 2009
1 answer
44 views
I saw inconsistent appearance for IE and FF. In FF, the select upper bound of select button is align with upper bound of input text box. But in IE, the upper bound of select is a bit lower than input text box.

Is there any script or property to set the location of select button to align it with input text box.

Thanks.


Paul
Telerik team
 answered on 02 Jul 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
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
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?