Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
1.1K+ views

Hello,

I have a user registration web form page where users have to enter specific fields. 

I go through and fill out the info but when I leave a required field blank I have a server side error check.  When it does the error check I lose the document within my radAsyncUpload control.    The file is already saved in the App_Data till I save it when the post is error free.

 

Can the control hold the file information till an error free post back is made?

I don't want my users to have to select their file multiple times.

 

Thank you,

Jerry

Rumen
Telerik team
 answered on 13 Aug 2019
7 answers
527 views
Hi We are trying to use ImageGallery but cannot make it properly responsive.

It seems that we can only set a fixed height in pixels so that the gallery shrinks horizontally but does not stay in proportion. The gallery height in the settings wizard cannot be left blank, cannot be set to a percentage or auto as then we get a run time error.  The height value writes css inline so we can't even over-ride it

If we remove it in Firebug the gallery becomes properly responsive

Does anyone know a way to solve this issue? We could just use a different gallery but this is the only problem we have 


Rumen
Telerik team
 answered on 13 Aug 2019
1 answer
222 views
I've seen the controls that are available in the Image editor and would really like to see them implemented in the image gallery. Being able to allow the client to specify image zoom, or other effects has a great value. I was curious if there was any simple solution currently to show a client a list of image thumbnails, and to open a single one in an editor.
Rumen
Telerik team
 answered on 13 Aug 2019
1 answer
98 views

According to the documentation there should be a way to set the location of the axis label position via property
    Telerik.Web.UI.HtmlChart.AxisLabelPosition. 

Which allow the values of: OnAxis, Start, or End

It is demonstrated in this demo

My version does not have that property. I am running "Telerik UI for ASP.NET AJAX R2 2018".  

Do I need a newer version?

Thanks, 
Mike H

 

 

Vessy
Telerik team
 answered on 12 Aug 2019
3 answers
428 views
Using ASP.Net webforms I have a pop up containing 2 tabs, which display info on a feature, 'FEATURE PROPERTIES' and 'IMAGES'. Each time a new feature is clicked the pop up is updated with the new feature details.

I was making the call back to the server where updatePanel8 was being updated. Unfortuantelly I am trying to convert my website to telerik and I am having difficulties implenting this. I have read many Q's on telerik forms some suggest trying RadAjaxPanel others suggest tryiing RadAjaxManager, but either way I cant seem to get it working as I cant use an update panel inside a panel when I am using telerik.

<asp:Panel ID="ViewFeatureProperties" runat="server" BackColor="Snow" Width="300"
               HorizontalAlign="Center">
               <asp:UpdatePanel runat="server" ID="UpdatePanel8" UpdateMode="Conditional" ChildrenAsTriggers="true"
                   Style="position: relative; overflow: hidden; background-color: White;              
                  width: 300px; height: 300px; margin: 5px; text-align: center; outline-style: none; overflow-y: hidden; overflow-x:hidden;">
 
                   <ContentTemplate>
                           <div id="DivHolding2Tabs" class="overflowcontent webkit-scrollbar webkit-scrollbar-track webkit-scrollbar-thumb" style="width:100%;border-color:Black;border-width:1px;border-style:solid;">
                               <ul id="tabList" style="width:100%">
                                   <li><a href="#tabs-1">Info</a> </li>
                                   <li><a href="#tabs-2" style="display:none;">Images</a> </li>
                               </ul>
 
                               <div id="tabs-1" class="WorkFlowLayout">
                                       <b><font color="FF6600">Feature Properties </font></b>
                                        <div id="divFeatureInfo" runat="server">
                                        </div>
                               </div>
 
                               <div id="tabs-2" class="WorkFlowLayout">
                                        <b><font color="FF6600">Images</font></b>
                                        <div id="ImagesRelatingToFeatureDIV" runat="server"
                                       </div>
                               </div>
                           </div>
                           <br />
                           <br />
                           <div class="buttonwrap">
                               <span id="Span5" class="ActionBtns">
                                   <asp:Button ID="ViewFeatureWorkflowImagePostBackBtn" runat="server" Style="display: none;
                                       visibility: hidden;" OnClick="ViewFeatureWorkflowImagePostBackBtn_Click" />
                               </span>
                           </div>
 
                   </ContentTemplate>
                   <Triggers>
                       <asp:AsyncPostBackTrigger ControlID="ViewFeatureWorkflowImagePostBackBtn" EventName="Click" />
                   </Triggers>
               </asp:UpdatePanel>
           </asp:Panel>

**CODE BEHIND**<br>protected void ViewFeatureWorkflowImagePostBackBtn_Click(object sender, EventArgs e)<br>{<br>ReloadUploadedImagesForFeatureWorkflow();<br>}<br><br><br>private void ReloadUploadedImagesForFeatureWorkflow()<br>{<br>//generate the new details for the popup<br>UpdatePanel8.Update();<br>script.Append("OpenPropertiesPopUp();");<br><br>ScriptManager.RegisterClientScriptBlock(UpdatePanel8,                                                        UpdatePanel8.GetType(),                                             "OpenPropertiesPopupCall()",<br>script.ToString(),<br>true);<br>}


Some exmaples I have tried are:

<asp:Panel ID="Panel1" runat="server">
                    <div id="Div1" class="overflowcontent webkit-scrollbar webkit-scrollbar-track webkit-scrollbar-thumb"
                         style="width: 100%; border-color: Black; border-width: 1px; border-style: solid;">
 
                     <asp:Button ID="ViewFeatureWorkflowImagePostBackBtn" runat="server" Text="Update the first Panel" OnClick="ViewFeatureWorkflowImagePostBackBtn_Click" />
                     <asp:Label ID="Label4" runat="server" Text="Label4"></asp:Label>
 
 
                         <ul id="Ul1" style="width: 100%">
                             <li><a href="#tabs-1">Info</a> </li>
                             <li><a href="#tabs-2" style="display: none;">Images</a> </li>
                         </ul>
                         <div id="tabs-1" class="WorkFlowLayout">
                             <b><font color="FF6600">Feature Properties </font></b>
                             <div id="divFeatureInfo" runat="server">
                             </div>
                         </div>
                         <div id="tabs-2" class="WorkFlowLayout">
                             <b><font color="FF6600">Images</font></b>
                             <div id="ImagesRelatingToFeatureDIV" runat="server">
                             </div>
                         </div>
                     </div>
                     <br />
                     <br />
                     <div class="buttonwrap">
                         <span id="Span6" class="ActionBtns">
                             <asp:Button ID="Button2" runat="server" Style="display: none; visibility: hidden;"
                                 OnClick="ViewFeatureWorkflowImagePostBackBtn_Click" />
                         </span>
                     </div>
 
     </asp:Panel>
     <br />
 
        <telerik:radajaxloadingpanel id="RadAjaxLoadingPanel2" runat="server" skin="Default"></telerik:radajaxloadingpanel>

code behind UpdatePanel8.AjaxRequest;
// UpdatePanel8.ResponseScripts.Add(String.Format("$find('{0}').ajaxRequest();", UpdatePanel8.ClientID));

Rumen
Telerik team
 answered on 12 Aug 2019
1 answer
95 views

Hello, have good time
I have a page where it's a grid.

In this grid one of the columns is hidden where the user ID is and in the other column it fills the user name with another List in the event ItemDataBound
But when grouping it shows the user ID while I need the name to show it.

Aspx

01.<telerik:RadGrid ID="RadGrid1" runat="server" ShowFooter="true" AllowFilteringByColumn="true" GroupingEnabled="true" ShowGroupPanel="True"
02.                ClientSettings-AllowDragToGroup="true" AllowSorting="true" AllowPaging="true" PageSize="5" Skin="WebBlue" AllowMultiRowSelection="false" CellSpacing="-1" GridLines="Both"
03.                OnSelectedIndexChanged="RadGrid1_SelectedIndexChanged" OnPageIndexChanged="RadGrid1_PageIndexChanged" OnItemDataBound="RadGrid1_ItemDataBound">
04.                <ClientSettings EnablePostBackOnRowClick="true">
05.                    <Selecting AllowRowSelect="True" />
06.                    <ClientEvents OnRowCreated="onRowCreated" OnRowSelected="onRowSelected" OnRowDeselected="onRowDeselected"
07.                        OnGridCreated="gridCreated" OnGridCreating="masterTableCreating" />
08.                </ClientSettings>
09.                <GroupingSettings ShowUnGroupButton="true" GroupContinuesFormatString="" />
10.                <MasterTableView ShowGroupFooter="true" AutoGenerateColumns="False" DataKeyNames="Food_User_ID" ClientDataKeyNames="Food_ID_"
11.                    NoMasterRecordsText="اطلاعاتی برای نمایش وجود ندارد">
12.                    <Columns>
13.                        <telerik:GridClientSelectColumn UniqueName="SelectColumn" Visible="true" />
14.                        <telerik:GridTemplateColumn HeaderText="ردیف" ItemStyle-HorizontalAlign="Center" HeaderStyle-Width="100px" Groupable="false">
15.                            <ItemTemplate><%# (Container.ItemIndex+1).ToString() %> </ItemTemplate>
16.                        </telerik:GridTemplateColumn>
17.                        <telerik:GridBoundColumn DataField="Food_ID_" Groupable="false" DataType="System.Int32" FilterControlAltText="Filter Food_ID_ column"
18.                            HeaderText="" ReadOnly="True" SortExpression="Food_ID_" UniqueName="Food_ID_" Visible="false" />
19.                        <telerik:GridBoundColumn DataField="Food_Name" Groupable="true" FilterControlAltText="Filter Food_Name column"
20.                            HeaderText="نام" SortExpression="Food_Name" UniqueName="Food_Name" />
21.                        <telerik:GridBoundColumn DataField="Food_Price" Groupable="true" FilterControlAltText="Filter Food_Price column"
22.                            HeaderText="قیمت" SortExpression="Food_Price" UniqueName="Food_Price" DataType="System.Int32" />
23.                        <telerik:GridBoundColumn DataField="Food_Image" Groupable="false" FilterControlAltText="Filter Food_Image column"
24.                            HeaderText="تصویر" SortExpression="Food_Image" UniqueName="Food_Image" />
25.                        <telerik:GridBoundColumn DataField="Food_User_ID" Groupable="false" SortExpression="Food_User_ID"
26.                            HeaderText="" UniqueName="User_ID" DataType="System.Int32" Visible="false" />
27.                        <telerik:GridBoundColumn DataField="Food_User_ID" Groupable="true" FilterControlAltText="Filter Food_User_ID column"
28.                            HeaderText="کاربر" SortExpression="Food_User_ID" UniqueName="UserFLName" DataType="System.Int32" />
29.                        <telerik:GridCheckBoxColumn DataField="Food_Status" Groupable="false" DataType="System.Boolean" FilterControlAltText="Filter Food_Status column"
30.                            HeaderText="وضعیت" SortExpression="Food_Status" UniqueName="Food_Status" />
31.                    </Columns>
32.                </MasterTableView>
33.                <FilterMenu></FilterMenu>
34.                <HeaderContextMenu RenderMode="Classic"></HeaderContextMenu>
35.            </telerik:RadGrid>

 

C#

01.protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e)
02.        {
03.            if (e.Item is GridDataItem)// to access a row
04.            {
05.                GridDataItem item = (GridDataItem)e.Item;
06.                if (RadGrid1.GroupingEnabled)
07.                {
08.                    item["UserFLName"].Text = LstUser.FindAll(x => x.User_ID_ == int.Parse(item["User_ID"].Text))[0].User_FName + " " + LstUser.FindAll(x => x.User_ID_ == int.Parse(item["User_ID"].Text))[0].User_LName;
09.                }
10.            }
11.}
Attila Antal
Telerik team
 answered on 09 Aug 2019
3 answers
217 views

Hi;

We have a .net webforms page that selects a file via a RadAsyncUpload control (the upload part is working fine).  After the file has been selected and transferred to the server in the background by the async upload, the user clicks a button to begin processing the file in the page's code-behind. 

We had previously created added a ProgressArea to the page, hoping that the communication between the server and the client would prevent the page from timing out during long processes (the processing of a file can take up to 30 minutes).  However, while the ProgressArea worked and was a definite improvement, the page request would still not have the response sent until the entire code-behind processing was complete, and thus the page would hit the http timeout limit (2 mins by default, I believe) before the server was finished processing, and we would get a "System.Web.HttpException (0x80004005): Request timed out." error.  Finally, we ended up just extending that page's timeout to an hour with the code

 

Server.ScriptTimeout = 3600;

in the Page_Load event.

However, our product is available not just hosted on our servers but also as an on-site web application on customers' servers -- this addresses security issues and regulations some of our customers have.  As a result, we do not have full control over the environment in which the software runs.  We've recently had a customer add AWS Cloudfront for content delivery, which has its own timeout settings.  This customer does not wish to set their Cloudfront http timeout to an hour, so our setting on the web application page doesn't matter.

What I am looking for is a way to keep that full response (as initiated by the user clicking the "Process" button) from timing out by keeping the server and client communicating during the processing in such a way as the http timeout doesn't get hit.  If I understand correctly, the ProgressArea sending information back from the server to the client does not "count" as part of the response the page is waiting for, so does not keep the http connection alive to prevent a timeout.

I had previously tried explicitly calling the processing from an ajax post from in a loop on the client, and while I was able to do this, the performance was drastically impacted for the worse.

Is there any way with the ProgressArea, ProgressManager, or some other telerik control to keep an http connection alive for the duration of a long process without having to change the timeout settings of any layer between the client and the web server?

Thanks!

Peter Milchev
Telerik team
 answered on 09 Aug 2019
1 answer
344 views
We're working on optimizing a page and found that it takes a while to download the ScriptResource.axd.  We downloaded this file and would like to use the local version instead of downloading it each time the page loads.  How would I reference the local version instead?
Rumen
Telerik team
 answered on 09 Aug 2019
12 answers
1.6K+ views
Hi,

How do I make the GridNumericColumn display negative numbers in the folowing "$ -40.00" format.  RadNumericTextbox has a NegativePattern, but I'm not able to set a negative pattern in GridNumericColumn.  GridNumericColumn seems to display negative values in "($40.00)" format.

This is annoying.

Thanks,
Brian
Sasp
Top achievements
Rank 1
 answered on 09 Aug 2019
4 answers
189 views

I am trying to change the font size for axes labels from the client. I was able to do so with series labels as follows:

var chart = $find(chartname);
var kw = chart.get_kendoWidget();
kw.options.title.font = kw.options.title.font.replace("16px", "12px");
kw.options.series[2].labels.from.font = kw.options.series[2].labels.from.font.replace("12px", "8px");
kw.refresh();

 

And this works well for the series labels and the title font. However, when trying to change the axis labels in this way:

kw.options.xAxis.labels.font=kw.options.xAxis.labels.font.replace("12px","6px")

 

It does not seem to have any effect. Is this a bug? Or am I going about this the wrong way?

In case anyone is interested, the reason i am doing this is because I am exporting to PDF (with rad export manager) and there does not seem to be a way to scale the content to "fit to page" except changing the content size. (outside of asking the user to check the "fit to page" option when printing the pdf.  

Vessy
Telerik team
 answered on 09 Aug 2019
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?