Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
178 views
Hi,
Is there a method on client side to refresh a RadCalendar, which re-renders days but does not call onCalendarViewChanged?
Daniel
Telerik team
 answered on 12 Mar 2009
3 answers
139 views

Hallo,

I am having trouble retrieving the updated time value that users enter into my dateinput control of my raddatetimepicker that is within an EditItemTemplate in my Radgrid. On server side the values are persisting, meaning that they  are the same values that loaded when the grid loaded originally, I have also tried swithing off EnableViewState and I have also tried an Editmanager.

Could you please provide met with further ideas about what to do next? Below is aspx snippet and c# snippet. Thank you.

<ItemTemplate>  
<telerik:RadDateTimePicker ID="rdtpStartingTimeData" Enabled="false" runat="server" Calendar-DatePopupButton-Visible="false" DatePopupButton-Visible="false"                                                     SelectedDate='<%# DataBinder.Eval(Container, "DataItem.TimeStart") %>' DateInput-DateFormat="hh:mm" Culture="English (South Africa)" TimeView-TimeFormat="HH:mm" TimeView-Columns="4">  
</telerik:RadDateTimePicker>  
</ItemTemplate>  
<EditItemTemplate>  
<telerik:RadDateTimePicker ID="rdtpStartingTime" runat="server" Calendar-DatePopupButton-Visible="false" DatePopupButton-Visible="false" EnableViewState="false" DateInput-Visible="true" SelectedDate='<%# DataBinder.Eval(Container,"DataItem.TimeStart") %>' DateInput-DateFormat="hh:mm" Culture="English (South Africa)" TimeView-TimeFormat="HH:mm" TimeView-Columns="4">  
</EditItemTemplate>  
</telerik:GridTemplateColumn> 

 if (e.CommandName == Telerik.Web.UI.RadGrid.UpdateCommandName)  
            {  
                Telerik.Web.UI.GridEditableItem editedItem = e.Item as Telerik.Web.UI.GridEditableItem;  
 
                Telerik.Web.UI.RadDateTimePicker rdtpStartTime = (Telerik.Web.UI.RadDateTimePicker)editedItem.FindControl("rdtpStartingTime");  
                Telerik.Web.UI.RadDateTimePicker rdtpEndTime = (Telerik.Web.UI.RadDateTimePicker)editedItem.FindControl("rdtpEndingTime");  
            }  
 

Princy
Top achievements
Rank 2
 answered on 12 Mar 2009
1 answer
39 views
I have a Rad tool bar that has 3 drop downs. I want each drop down to have a different data source. When i try to establish the data sourse I can only create a data sourse for the tool bar but not for the drop downs. Is there a way to have the drop downs have their own data sourse?
Atanas Korchev
Telerik team
 answered on 12 Mar 2009
1 answer
63 views
Requirement: create 30 min time slots from 8 - 5 and allow users to create upto 5 appointments for each slot.
Question: Can we accomplish this using Telerik Scheduler control?
Kamen Bundev
Telerik team
 answered on 12 Mar 2009
6 answers
246 views
Hello,

I have a RadComboBox that uses the ItemTemplate property to represent bound items in a table.  For whatever reason, in the HTML, it renders a surrounding <div> with style="display:block"; I actually need style="display:inline".  Is there a way to change this?

Thanks.
Simon
Telerik team
 answered on 12 Mar 2009
4 answers
177 views
Hi,
I have problem with data manipulation in "detail grid".
I have typed DataSet that is binded to MasterDataGrid....that master data grid has 5 columns that are related with 5 fields from one table (MasterTable) but, when i click on Edit in some row, then within <EditFormSettings EditFormType="Template"> i have offered to modify other columns from MasterTable...all key values for masterGrid i suggest within masterGrid_ItemCommand (if e.CommandName == RadGrid.InitInsertCommandName)...
then i have added detailGrid inside that EditFromSettings...
now the problem appear...when i try to use that detailGrid, i can't find it as control in masterGrid, so i can't add row in that grid...even if I add row (with button that has CommandName="PerformInsert"), that command line simply dissapear in grid...like i didn't add it at all...
If i explained it little bit confusy here is some code that will help me to be more precise:
<telerik:RadGrid id="masterGrid" runat="server" AllowMultiRowSelection="false" AutoGenerateEditColumn="true" AutoGenerateColumns="False" DataMember="MasterTable" DataSourceID="someDataSource" GridLines="None" OnItemCommand="masterGrid_ItemCommand"
  <IxMasterTableView DataKeyNames="Col1,Col2,Col3" DataMember="MasterTable" DataSourceID="someDataSource" SelectionItemDisplay="TopAndBottom" AllowSorting="True" AutoGenerateColumns="False" CommandItemDisplay="Top"
    <CommandItemTemplate> some button is here </CommandItemTemplate> 
    <Columns> 
      <telerik:GridBoundColumn DataField="Column1" HeaderText="Column1 name" ReadOnly="True" SortExpression="Column1" UniqueName="Column1" /> 
      and 4 columns more... 
    </Columns> 
    <EditFormSettings EditFormType="Template"
      <FormTemplate> 
        <table> 
          <tr><td>...some TextBox binded columns....</td><tr
          <tr> 
            <td> 
              <telerik:RadGrid ID="detailGrid" runat="server" SelectionEnabled="False" DataSourceID="someDataSource" GridLines="None" DataMember="DetailTable" AutoGenerateColumns="False" AllowSorting="True" OnItemCommand="detailGrid_ItemCommand"
                <IxMasterTableView DataKeyNames="Col1,Col2,Col3,Col4,Col5" DataMember="DetailTable" DataSourceID="someDataSource" SelectionItemDisplay="TopAndBottom" AllowSorting="True" AutoGenerateColumns="False" CommandItemDisplay="Top"
                  <CommandItemTemplate> some button is here </CommandItemTemplate> 
                  <Columns> 
                    <telerik:GridTemplateColumn HeaderText="first" UniqueName="Col1" DataField="Col1" SortExpression="Col1"
                      <ItemTemplate> 
                          ...some link button... 
                      </ItemTemplate> 
                      <EditItemTemplate> 
                        ...some TextBox control... 
                      </EditItemTemplate> 
                    <telerik:GridTemplateColumn> 
                      ...and couple more GridTemplateControls... 
                      ...and last column in grid is something like this... 
                    <telerik:GridTemplateColumn UniqueName="ColumnDelete"
                      <ItemTemplate> 
                         <asp:Button ID="deleteButton" runat="server" Text="Del" CommandName="Delete" /> 
                      </ItemTemplate> 
                      <EditItemTemplate> 
                        <asp:Button ID="addButton" Text="Add" Visible='<%# don't know how to implement as it is in masterGrid %>runat="server" CommandName="PerformInsert" />&nbsp; 
                        <asp:Button ID="updateButton" Text="Update" Visible='<%# same as previous, just on update %>' runat="server" CommandName="Update" />&nbsp; 
                        <asp:Button ID="cancelButton" Text="Cancel" runat="server" CausesValidation="False" CommandName="Cancel" /> 
                      </EditItemTemplate> 
                      <HeaderStyle /> 
                      <ItemStyle HorizontalAlign="Right" /> 
                    </telerik:GridTemplateColumn> 
                  </Columns> 
              </telerik:RadGrid> 
            </td> 
          </tr> 
          <tr> 
            <td> 
              <asp:Button ID="addMaster" Text="Add" Visible='<%# (masterGrid.IxMasterTableView.IsItemInserted) %>' runat="server" CommandName="PerformInsert" />&nbsp; 
              <asp:Button ID="updateMaster" Text="Update" Visible='<%# !(masterGrid.IxMasterTableView.IsItemInserted) %>' runat="server" CommandName="Update" />&nbsp; 
              <asp:Button ID="cancelMaster" Text="Cancel" runat="server" CausesValidation="False" CommandName="Cancel" /> 
            </td> 
          </tr> 
        </table> 
      </FormTemplate> 
    </EditFormSettings> 
  </IxMasterTableView> 
</telerik:RadGrid> 

and here is some codebehind for onItemCommand
DataKey oldKeyValues = e.Item.OwnerTableView.DataKeyValues[0]; 
RadGrid detailRadGrid = (sender as RadGrid); 
 
if (e.CommandName == RadGrid.InitInsertCommandName) { 
  detailRadGrid.Save(false); 
  aoGridCommandEventArgs.Canceled = true
  System.Collections.Specialized.ListDictionary newKeyValues = new System.Collections.Specialized.ListDictionary(); 
  if (loDataKey != null) { 
    newKeyValues["Col1"] = oldKeyValues["Col1"]; 
    newKeyValues["Col2"] = oldKeyValues["Col2"]; 
    newKeyValues["Col3"] = oldKeyValues["Col3"]; 
    newKeyValues["Col4"] = oldKeyValues["Col4"]; 
    e.Item.OwnerTableView.InsertItem(newKeyValues); 
  } 

same is for masterGrid...
So, my question would be...how can i add and save value in detailGrid, because this way it is not functioning, and is it possible to filter detailGrid rows to display only rows that are related to masterGrid column that is not in KeyColumns ?
and how can i check which row in rows 33 and 34 (of first code part) will be visible based on logic in rows 46 and 47 ?
Some example of how to use this would be great...i'm stuck here fot 10 days and can't move any further...
Thanks for reply...
Tsvetoslav
Telerik team
 answered on 12 Mar 2009
1 answer
97 views
I have the problem where, when my grid is shown in a reduced space, i.e. not the whole page, and the columns all shrink, but the inputs in the filter row seem to keep the column width, and not shrink proportionally to allow the filter icon to remain visible.  Any suggestions?
Yavor
Telerik team
 answered on 12 Mar 2009
1 answer
87 views
Hi Team,

Is there a way to access the opposite of the ClientEvents-OnColumnContextMenu event? What I am trying to accomplish is having the user right-click on the columns, and specify one to many columns to display / hide, and when they are are done selecting the columns to perform an ajax request to resize the width of the grid.

I have tried to wire to the event ClientEvents-OnColumnHidden and ClientEvents-OnColumnShown but these events fire every time that a single column is hidden or shown, and the ajax processing causes the context menu to close, preventing the user from selecting / deselecting all of the desired columns.

Any help is appreciated.

-Matt
Yavor
Telerik team
 answered on 12 Mar 2009
1 answer
63 views
I have filters on my radgrid.  One of my columns is a checkbox column:
<radg:GridTemplateColumn HeaderStyle-Width="40px" ItemStyle-Width="40px" AllowFiltering="false"  
                                        HeaderText="In/Out" UniqueName="ownershipcolumn"
                                       <ItemTemplate> 
                                          <asp:CheckBox AutoPostBack="true" id="chkOwned" runat="server"></asp:CheckBox> 
                                       </ItemTemplate> 
                                    </radg:GridTemplateColumn> 

After I filter the grid my gridcommandeventargs always have an e.item with a TypeOf "GridFilteringItem" instead of a "GridDataItem."

It's like the filter is the only thing sending events now instead of whichever row/control I click on.  The GridFilteringItem always has a DataItem = Nothing as well.

Since the filter is the only thing firing events I cannot capture my CheckBox.CheckChanged event.

Any hints?


Yavor
Telerik team
 answered on 12 Mar 2009
2 answers
226 views
How would I achieve this?  The demo for load on demand adds new RadComboBoxItem objects to the combo, but these only have text and value properties.  I think I have to somehow get and populate the ItemTemplate for the combo, but that's where I get lost.  Any help will be appreciated.

Martin
Top achievements
Rank 1
 answered on 12 Mar 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?