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

On my first page of listview i have 10 items with check box in item template.
Suppose user has checked 2 checkboxes and click on 2nd page index.  Then we prompt user that "few items are selected in current page
take appropiate action" in rad window.
If user select any action by clicking on "button".  page index should not be changed because we want item value for checked items.
But if user select "cancel button" then page index should be changed.

How to achieve this functionality in C#?

Thanks,
Dipal

Andrey
Telerik team
 answered on 28 Nov 2012
4 answers
1.4K+ views
I have the following grid:
<telerik:RadGrid ID="RadGridAziendeForUser" runat="server" DataSourceID="ObjectDataSourceAziendeUtente" 
                EnableEmbeddedSkins="False" GridLines="None" Skin="MachinaWeb" AllowAutomaticUpdates="True" 
                AllowAutomaticDeletes="True" AllowAutomaticInserts="True" AllowMultiRowSelection="True" 
                AutoGenerateEditColumn="True"  
                OnItemCommand="RadGridAziendeForUser_ItemCommand"
                <ClientSettings EnablePostBackOnRowClick="True"
                    <Selecting AllowRowSelect="True" /> 
                    <Scrolling EnableVirtualScrollPaging="True" ScrollHeight="200px" /> 
                </ClientSettings> 
                <MasterTableView AutoGenerateColumns="False" DataSourceID="ObjectDataSourceAziendeUtente" 
                    EditMode="InPlace" CommandItemDisplay="Top" DataKeyNames="IdUtente,IdAzienda"
                    <CommandItemTemplate> 
                        <div style="float: left;"
                            <asp:LinkButton Text="Nuova Azienda" ID="Insert" runat="server" CommandName="InitInsert" /> 
                        </div> 
                    </CommandItemTemplate> 
                    <RowIndicatorColumn> 
                        <HeaderStyle Width="20px" /> 
                    </RowIndicatorColumn> 
                    <ExpandCollapseColumn> 
                        <HeaderStyle Width="20px" /> 
                    </ExpandCollapseColumn> 
                    <Columns> 
                        <telerik:GridBoundColumn DataField="IdUtente" DataType="System.Int64" HeaderText="IdUtente" 
                            ReadOnly="True" SortExpression="IdUtente" UniqueName="IdUtente" Visible="false"
                        </telerik:GridBoundColumn> 
                        <telerik:GridBoundColumn DataField="IdUtenteAsp" HeaderText="IdUtenteAsp" SortExpression="IdUtenteAsp" 
                            UniqueName="IdUtenteAsp" DataType="System.Guid" Visible="false"
                        </telerik:GridBoundColumn> 
                        <telerik:GridBoundColumn DataField="UserName" HeaderText="UserName" ReadOnly="True" 
                            SortExpression="UserName" UniqueName="UserName" Visible="false"
                        </telerik:GridBoundColumn> 
                        <telerik:GridBoundColumn DataField="IdCultura" DataType="System.Int64" HeaderText="IdCultura" 
                            ReadOnly="True" SortExpression="IdCultura" UniqueName="IdCultura" Visible="false"
                        </telerik:GridBoundColumn> 
                        <telerik:GridTemplateColumn> 
                            <HeaderTemplate> 
                                <asp:Label ID="Label46" runat="server" Text="Azienda"></asp:Label> 
                            </HeaderTemplate> 
                            <EditItemTemplate> 
                                <telerik:RadComboBox ID="AziendaRadComboBox" runat="server" DataSourceID="ObjectDataSourceAzienda" 
                                    DataTextField="NomeAzienda" DataValueField="IdAzienda" SelectedValue='<%# Bind("IdAzienda") %>' 
                                    Width="120px" /> 
                            </EditItemTemplate> 
                            <ItemTemplate> 
                                <asp:Label ID="Label47" runat="server" Width="120px" Text='<%# Bind("Azienda") %>'></asp:Label> 
                            </ItemTemplate> 
                        </telerik:GridTemplateColumn> 
                        <telerik:GridTemplateColumn> 
                            <HeaderTemplate> 
                                <asp:Label ID="Label48" runat="server" Text="Cultura"></asp:Label> 
                            </HeaderTemplate> 
                            <EditItemTemplate> 
                                <telerik:RadComboBox ID="CulturaRadComboBox" runat="server" DataSourceID="ObjectDataSourceCultura" 
                                    DataTextField="Cultura" DataValueField="IdCultura" SelectedValue='<%# Bind("IdCultura") %>' 
                                    Width="70px" /> 
                            </EditItemTemplate> 
                            <ItemTemplate> 
                                <asp:Label ID="Label50" runat="server" Width="70px" Text='<%# Bind("Cultura") %>'></asp:Label> 
                            </ItemTemplate> 
                        </telerik:GridTemplateColumn> 
                        <telerik:GridTemplateColumn> 
                            <HeaderTemplate> 
                                <asp:Label ID="Label49" runat="server" Text="Gruppo"></asp:Label> 
                            </HeaderTemplate> 
                            <EditItemTemplate> 
                                <telerik:RadComboBox ID="GruppoRadComboBox" runat="server" DataSourceID="ObjectDataSourceGruppoUtente" 
                                    DataTextField="Nome" DataValueField="IdGruppoUtente" SelectedValue='<%# Bind("IdGruppo") %>' 
                                    Width="120px" /> 
                            </EditItemTemplate> 
                            <ItemTemplate> 
                                <asp:Label ID="Label51" runat="server" Text='<%# Bind("Gruppo") %>'></asp:Label> 
                            </ItemTemplate> 
                        </telerik:GridTemplateColumn> 
                        <telerik:GridTemplateColumn> 
                            <HeaderTemplate> 
                                <asp:Label ID="Label52" runat="server" Text="Stabilimento"></asp:Label> 
                            </HeaderTemplate> 
                            <EditItemTemplate> 
                                <telerik:RadComboBox ID="StabilimentoRadComboBox" runat="server" DataSourceID="ObjectDataSourceStabilimento" 
                                    DataTextField="Denominazione" DataValueField="IdStabilimento" SelectedValue='<%# Bind("IdStabilimento") %>' 
                                    Width="120px" /> 
                            </EditItemTemplate> 
                            <ItemTemplate> 
                                <asp:Label ID="Label53" runat="server" Text='<%# Bind("Stabilimento") %>'></asp:Label> 
                            </ItemTemplate> 
                        </telerik:GridTemplateColumn> 
                        <telerik:GridTemplateColumn> 
                            <HeaderTemplate> 
                                <asp:Label ID="Label54" runat="server" Text="Reparto"></asp:Label> 
                            </HeaderTemplate> 
                            <EditItemTemplate> 
                                <telerik:RadComboBox ID="RepartoRadComboBox" runat="server" DataSourceID="ObjectDataSourceReparto" 
                                    DataTextField="Reparto" DataValueField="IdReparto" SelectedValue='<%# Bind("IdReparto") %>' 
                                    Width="120px" /> 
                            </EditItemTemplate> 
                            <ItemTemplate> 
                                <asp:Label ID="Label55" runat="server" Text='<%# Bind("Settore") %>'></asp:Label> 
                            </ItemTemplate> 
                        </telerik:GridTemplateColumn> 
                        <telerik:GridButtonColumn CommandName="Delete" Text="Delete" UniqueName="DeleteColumn" 
                            ConfirmText="Do you really want to delete the selected row?" /> 
                    </Columns> 
                    <EditFormSettings> 
                        <EditColumn> 
                        </EditColumn> 
                    </EditFormSettings> 
                </MasterTableView><FilterMenu EnableEmbeddedSkins="False"
                </FilterMenu> 
                <HeaderContextMenu EnableEmbeddedSkins="False"
                </HeaderContextMenu> 
            </telerik:RadGrid> 

I want to access by code the GridTemplateColumn's HeaderTemplate Labels (for example "Label46") to change the Text property. How can I do this in C#?

Thanks.
Carlos
Top achievements
Rank 2
 answered on 28 Nov 2012
1 answer
142 views
How can i disable autocomplete option in raddatepicker? 
Shinu
Top achievements
Rank 2
 answered on 28 Nov 2012
1 answer
86 views
How can i access the input box of the raddatepicker in the client side? 
Princy
Top achievements
Rank 2
 answered on 28 Nov 2012
1 answer
77 views
hi,
i've a problem with upload file with radupload. When i do upload i've thsi message:

ASP.NET is not authorized to access the requested resource. Consider granting access rights to the resource to the ASP.NET request identity. ASP.NET has a base process identity (typically {MACHINE}\ASPNET on IIS 5 or Network Service on IIS 6 and IIS 7, and the configured application pool identity on IIS 7.5) that is used if the application is not impersonating. If the application is impersonating via <identity impersonate="true"/>, the identity will be the anonymous user (typically IUSR_MACHINENAME) or the authenticated request user.

I dont know as configure the access. Please help me for exaple is possible

bye
Plamen
Telerik team
 answered on 28 Nov 2012
2 answers
64 views
hi team

can i use the classic jquery (jquery ui) dialog box instead of Advanced Form for insert/edit data ?


thanks
Plamen
Telerik team
 answered on 28 Nov 2012
1 answer
76 views
I want to attachment mail so i use AsyncUpload :


 <telerik:RadAsyncUpload runat="server" ID="rad_upload" Skin="Default" OnClientFileUploadFailed="onUploadFailed"<br>                                            OnClientFileSelected="onFileSelected" OnClientFileUploaded="onFileUploaded" Culture="Arabic" TemporaryFileExpiration="00:07:00" > <Localization Select="اختر" /> </telerik:RadAsyncUpload>
 List<Attachment> attach = new List<Attachment>(); if (rad_upload.UploadedFiles != null && rad_upload.UploadedFiles.Count > 0){; foreach (UploadedFile file in rad_upload.UploadedFiles){; Attachment f = new Attachment(Server.MapPath("~/App_Data/RadUploadTemp/") + file.GetName(), file.ContentType); attach.Add(f); }

I get an exception File not found !! how attach the file with this method
Plamen
Telerik team
 answered on 28 Nov 2012
1 answer
105 views

How do I get search engine results programatically?  Some search engines use AJAX to display content and so the URL does not change. This makes it difficult to get result content from a search engine programatically.

Most search engines do not use AJAX.  But two popular ones that I am interested in is YANDEX and DUCKDUCKGO.  Both of these search engines use AJAX to advance beyond the first page of results.  How do I find a way to programatically access these pages?

Vasil
Telerik team
 answered on 28 Nov 2012
6 answers
163 views

Hi,
since the sql select using the radcombox charged over 1000 records, you can upload a video, when I open the radcombobox, only 10 records at a time? And then you decide to continue to view other records.
Maybe I need to use the property ShowMoreresultsBox = True?
My side code vb net is:

Protected Sub RadComboBox1_ItemsRequested(sender As Object, e As Telerik.Web.UI.RadComboBoxItemsRequestedEventArgs) Handles RadComboBox1.ItemsRequested
 
Dim sqlSelectCommand As String = "SELECT [id], [descrizione] from [tab_categorie] WHERE [descrizione] LIKE @desc + '%' Order By [descrizione]"
  
Dim adapter As New SqlDataAdapter(sqlSelectCommand, ConfigurationManager.ConnectionStrings("TrycontactString").ConnectionString)
 
 adapter.SelectCommand.Parameters.AddWithValue("@desc", e.Text)
 
 Dim dataTable As New DataTable()
 
 adapter.Fill(dataTable)
 For Each dataRow As DataRow In dataTable.Rows
 
 Dim item As New RadComboBoxItem()
 
 item.Text = DirectCast(dataRow("descrizione"), String)
 
item.Value=dataRow("id").ToString()radComboBox1.Items.Add(item)
 
 item.DataBind()
 
 Next
End Sub

 

 

 

While the ASP side code is:

<telerik:RadComboBox ID="RadComboBox1" Runat="server" DropDownWidth="325px"
    EmptyMessage="Choose a Catogory" EnableLoadOnDemand="true" Filter="Contains"
    Height="150" HighlightTemplatedItems="true"
    OnItemsRequested="RadComboBox1_ItemsRequested"
    Width="325px" ErrorMessage="Dato errato" IsCaseSensitive="True">
</telerik:RadComboBox>

 

 

 

 

 

 



Nencho
Telerik team
 answered on 28 Nov 2012
1 answer
91 views
I have a page with RadFileExplorer and EnableAsyncUpload="true" option. We are using selenium tool for automation testing. But we are not able to perform "click" option with EnableAsyncUpload option.

If i remove EnableAsyncUpload option then i am able to do it.

Our findings are as below
---------------------------------------------------------------------------------------------

1) There are 2 separate objects, a "text" and a "button"  manually clicking on which the Select File window opens. However, through Select IDE and Selenium RC, on performing click on these objects, the Select File window does not open, due to which AutoIT is unable to select the file to upload. This looks to be more of a selenium issue that though the Click action is executing successfully, the click event is not getting fired and the Select File Window is not invoked.

I am able to perform a "type" in the text box.However, the file is not uploaded by doing a type as your application does not support that.

2) Using the IE developer tool, it is highlighting the file object as below

               <OBJECT style="OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: 0pt; WIDTH: 100%" id=ctl00_BodyContent_FileExplorer_asyncUpload1flash010 class=ruObject tabIndex=-1 data="/WebResource.axd?d=fM8n8mufwaYAdyK9bnynX5Wn47jvXke8iOMZ_ZStmCnM1bULR6bY0YLeP07v4HddNqGy_TB-zp3JF322tlXRhdAuS5pvAT1tz_SSdoa36qh9eBXYTd1gcKF-tJC8bfmPYbJBTE_Kt8mQoALLyvR9XPA32SbcoMKjJe_pbWbJu0QS1ni81X8-Vi_6J6-CUY-70&amp;t=634770601240000000" type=application/x-shockwave-flash height=22></OBJECT>

Usually, to upload a file, the html input object used is of the "type=file" which I dont see in the above object.
Request you to have a word with your dev team and let us know if this object is a flash component   (Notice the "type" attribute).

--------------------------------------------------------------------------------------------

can anybody please provide any input?
Joana
Telerik team
 answered on 28 Nov 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?