Telerik Forums
UI for ASP.NET AJAX Forum
0 answers
138 views
hi, i can't delete appointments.. in debug mode i never enter the function
here's the RadScheduler code in aspx
<telerik:RadScheduler runat="server"
ID="RadScheduler1"
 Width="1000px"
    SelectedDate="01-01-2011"
     TimeZoneOffset="03:00:00"
     DayStartTime="08:00:00"
     DayEndTime="18:00:00"
    StartEditingInAdvancedForm="false"
     DataKeyField="ID"
      DataSubjectField="Subject"
    DataStartField="Start"
     DataEndField="End"
      DataRecurrenceField="RecurrenceRule"                  
     OnFormCreating="RadScheduler1_FormCreating"
    DataRecurrenceParentKeyField="RecurrenceParentID"
    Skin="WebBlue" Culture="it-IT" FirstDayOfWeek="Monday"
    LastDayOfWeek="Friday" SelectedView="WeekView" 
    OnAppointmentDelete="RadScheduler1_OnAppointmentDelete" 
    AppointmentStyleMode="Simple" OnAppointmentDataBound="RadScheduler1_AppointmentDataBound" AllowDelete="true" OnClientAppointmentDeleting="onAppointmentDeleting"
  >

and the function
protected void RadScheduler1_OnAppointmentDelete(object sender, SchedulerCancelEventArgs e)
 
{
 
    // I never go in this function
 
}

i also set proprietyAllowDelete="true"
i cant' understand why the event don't run.

thanks
Ale

Alessandro
Top achievements
Rank 1
 asked on 09 Feb 2011
1 answer
132 views
I'm working on an ASP.NET custom control that uses RadTreeView inside RadComboBox (largely following the example on the demo site). It's entirely client side and does not postback on its own, so all event handling is done using clientside JavaScript.

The control will be used in several places on a page and I would like to simplify the JavaScript that needs to be deployed to the client (since there's quite a bit). Right now, though, the "control" is just an ASP.NET WebForm.

In general, I am able to do a lot of DOM walking in order to find objects by their relative position, but this is falling apart when I try to locate the ComboBox from a TreeNode.

For instance, I'd like to do this (not working):
function GetRadComboBoxFromRadTreeViewElement(treeViewElement) {
    var htmlRoot = $(treeViewElement).closest('div.MyCustomControl'); // walk up to control container
    var comboBoxDiv = $(htmlRoot).find('div.SearchableTreeCombo'); // find ComboBox container
    return $find($(comboBoxDiv).attr('id')); // look up ComboBox object from containing div id
}

The idea is that I pass some element from a TreeNode event handler to this function and it traverses the DOM and returns the RadComboBox client object.

This is failing for me because the HTML generated looks like this (severely trimmed down):

<html>
  <body>
    <form>
      <div class="rcbSlide">
        <div id="RadComboBox1_DropDown" class="RadComboBoxDropDown" ></div>
      </div>
 
      <div class="MyCustomControl">
        <label for="RadComboBox1" id="treeListLabel">Field Label: </label>
        <div id="RadComboBox1" class="RadComboBox RadComboBox_Default SearchableTreeCombo">
          <input id="RadComboBox1_ClientState" name="RadComboBox1_ClientState" type="hidden">
        </div>
      </div>
    </form>
  </body>
</html>

The actual TreeView contents are rendered in the 'rcbSlide' div, which is added as the first element on the form. The remainder of my control logic resides inside the 'MyCustomControl' div. That makes DOM walking impossible (or does it?) when I have multiple instances of the control on one form. I don't have access to ASP.NET IDs (e.g. <%= RadComboBox1.ClientID => because the controls are generated dynamically and not statically declared in any markup).

I'm hoping there is actually a way I can find the TreeView from the ComboBox and vice versa using JavaScript that is generic and reusable. If I can't, I think the only method I can follow is to add a copy of all of the JavaScript for each control on the form, and customize each block of script for each instance of a control.

That's not particularly disastrous, but it means that a LOT of redundant JavaScript is being sent to a client. Right now my JS (unminified, mind you) is 26KB to support one instance of the control. Some users will have up to 10 of these on a form and I hate to add so much bloat to my pages when the differences between the script blocks is so minimal.


Can anyone suggest anything? Thanks!
Stefan
Top achievements
Rank 1
 answered on 09 Feb 2011
2 answers
124 views
Hi,

What i need to do is to change radconfirm buttons text so I addes sommething like that in my aspx:
<ConfirmTemplate>
    <div class="rwDialogPopup radconfirm">
        <div class="rwDialogText">
            {1}
        </div>
        <div>
            <a onclick="$find('{0}').close(true);" class="rwPopupButton" href="javascript:void(0);">
                <span class="rwOuterSpan"><span class="rwInnerSpan">EWKA</span></span></a>
            <a onclick="$find('{0}').close(false);" class="rwPopupButton" href="javascript:void(0);">
                <span class="rwOuterSpan"><span class="rwInnerSpan">RECZNY</span></span></a>
        </div>
    </div>
</ConfirmTemplate>
And I call my window from code behind like this:
ScriptManager.RegisterClientScriptBlock(Page, Me.GetType(), "NOSOURCE", "radconfirm('text for user?',confirmCallBackFnGoToHandMode)", True)
Now the problem is that I need two different confirms on the same page one with 'EWKA' and 'RECZNY' and one with 'OK' and 'CANCEL' buttons
Any idea how I can achive that??

Thanks
margan
Top achievements
Rank 1
 answered on 09 Feb 2011
1 answer
271 views
Hi,
Is there any client-side method to set imageurl property of the control at javascript?
Thanks,
Mira
Telerik team
 answered on 09 Feb 2011
1 answer
79 views
My grid is posting back with every click. I am using it inside a Visual web part in SharePoint 2010. SP2010 automatically has an ASP.NET script manager on the page so I am a little confused as to why it isn't acting all AJAXy?
Pavlina
Telerik team
 answered on 09 Feb 2011
1 answer
122 views
Any help with this problem would be appreciated (it isn't really Telerik specific)

I have a RadListView with an sqlDataSource. I have two problems. First I want to calculate a column in the sqldatasource. I have a table with a column called Owner and want to create a bool which indicates whether the present user is the owner of that record. ie

Select *, (Owner=@User) as mine where....

But this doesn't work so how can you calculate a columnwithin a select statement?

Second problem which is more related to the Rad control is that I am using an itemTemplate in the listView and would like to have a button within that template where I control the "visible" based on the value of the calculated column ("mine"). I have tried

Visible='<%#Eval("mine")%>'

but get a cast error (to avoid the first problem I have just calculated mine as 'true' in the datasource).

Iana Tsolova
Telerik team
 answered on 09 Feb 2011
1 answer
239 views
Hi,

1. I can hide Axis Scale visibility by setting  property. Visible="False"   but i need to hide only axis scale and minor ticks  not the Axis Major ticks and label.   How this can i handle this rad chart ? 

2.   Another thing  I need to show only the legend marker text  and i wanted to hide Legend Marker Figure  only,   Is it possible in Radchart ?



Evgenia
Telerik team
 answered on 09 Feb 2011
3 answers
120 views
Hi Telerik team,First of all thanks for this wonderful Controls.
but i am disappointment that you don't have much information about sharepoint 2010 integration i mean there is some video but they are basic.
I have question like will telerik Scheduler control both silverlight and ajax will recognize Sharepoint Calendar list recurrence pattern.also if you have an y example please give me link.

Please advise i really love Scheduler control and would like to work with it.

Thanks
Ronak
George
Telerik team
 answered on 09 Feb 2011
3 answers
157 views
Hi

I have created a Radchart successfuly using the following code

Dim sqlDataSource As New SqlDataSource()
sqlDataSource.ID = "myDataSource"
sqlDataSource.ConnectionString = "data source=" & Session("Server").ToString & "; initial catalog=" & Session("Database").ToString & "; Connect Timeout=5000; " & System.Configuration.ConfigurationManager.AppSettings("Credentials")
sqlDataSource.SelectCommand = "SELECT rtrim(substring([partnumber],patindex('%-%',partnumber) + 1, 50)) AS Location ,[wt101 Customer Calender].[Date] AS Date ,isnull(sum([BufferInventory]),0) AS Buffer FROM [wt273FEPGroupResults] INNER JOIN [wt101 Customer Calender] ON [wt273FEPGroupResults].[Date] = [wt101 Customer Calender].[Date] WHERE [wt101 Customer Calender].[Date] >= (select min(date) from [wt273FEPGroupResults] where [item] = '" & RTrim(txtItem.Text) & "') and [wt101 Customer Calender].[Date] <= (select max(date) from [wt273FEPGroupResults] where [item] = '" & RTrim(txtItem.Text) & "') and [item] = '" & RTrim(txtItem.Text) & "' GROUP BY rtrim(substring([partnumber],patindex('%-%',partnumber) + 1, 50)),[wt101 Customer Calender].[Date] ORDER BY [Location],[Date]"
Me.Page.Controls.Add(sqlDataSource)
radChart1.DataGroupColumn = "Location"
radChart1.PlotArea.XAxis.DataLabelsColumn = "Date"
radChart1.Legend.Appearance.GroupNameFormat = "#NAME: #VALUE"
radChart1.SeriesOrientation = ChartSeriesOrientation.Vertical
radChart1.DefaultType = ChartSeriesType.Line
radChart1.DataSourceID = "myDataSource"
radChart1.ChartTitle.TextBlock.Text = "Buffer Inventory by Location"
radChart1.PlotArea.XAxis.AutoScale = True
radChart1.DataBind()

All very straight forwards. The problem I have is that the chart shows the value of each data point on the chart.
Is there any way to get rid of these values and just show the lines?

Thanks in Advance

Yavor
Telerik team
 answered on 09 Feb 2011
0 answers
70 views
hi Telerik team,
I have got an javascript error with the radgridview.The scenario is  that i have a radgridview,which have edit/delete/update option.The issue is that when i do some edit and then press update,i got an javascript error in ie.i have attached the screen short of this.please provide help why it is happening.
Kuldeep
Top achievements
Rank 1
 asked on 09 Feb 2011
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?