Telerik Forums
UI for ASP.NET AJAX Forum
7 answers
483 views
Hello, i'm using RadAsyncUpload to send files to server. i am setting a postbacktrigger to button "save". The problem exists when a something goes wrong at server side.
for example: if some textbox has the incorrect format a valitonsummary displays the error message, but the uploaded files disappear, its like the control reset.

anyone knows how to stop the reset after PostbackTrigger?

thanks
Peter Milchev
Telerik team
 answered on 31 Aug 2020
2 answers
168 views

I need a Context Menu to pop up on right-clicking any Shape in RadDiagram, a different Context Menu upon right-clicking a Connection, and nothing at all on right-clicking white space.  I have experimented with setting "RadDiagram1" as a Target, but unlike the OnClick client-side event, which runs only if the user clicks on a shape or connection, setting the entire diagram as a Target does not differentiate between shape, connection and white space when right-clicked. So far, I have not found a way to specify a Shape or Connection as the Target.  Can somebody suggest a solution?  

Sheldon
Top achievements
Rank 1
 answered on 30 Aug 2020
9 answers
362 views

I have a user control that I dynamically create in the cells of a radcalendar. The control is based on the results of a database query that takes place in the DayRender event for each day of the calendar. Any given day can have zero, none or many of the user controls created within it. All this works fine, the problem is that none of the events associated with the user control ever get called when triggered. For instance if a checkbox is clicked the page will postback, but the event for this checkbox in the usercontrol doesn't execute. I know why this is, but I don't know how to fix it. Normally I would create/recreate my user controls in OnInit, but since this is happening in DayRender the controls don't exist when the page posts back. How can I get this to work?

Thank you,

John

(I had mistakenly posted this in the non-Ajax forum previously)

JeffSM
Top achievements
Rank 2
Iron
Veteran
Iron
 answered on 28 Aug 2020
1 answer
91 views
I have a radgrid that its datasource takes three inputs before executing.  I also want to allow for inserts to take place, but those three dropdown selections must be made prior to allowing a user to insert a record.  How can I prevent the edit form for showing if the selections are not made prior to clicking the Add New Record buttion on the radgrid?
Attila Antal
Telerik team
 answered on 28 Aug 2020
1 answer
198 views
I need a Context Menu to pop up on right-clicking any Shape in RadDiagram, a different Context Menu upon right-clicking a Connection, and nothing at all on right-clicking white space.  I have experimented with setting "RadDiagram1" as a Target, but unlike the OnClick client-side event, which runs only if the user clicks on a shape or connection, setting the entire diagram as a Target does not differentiate between shape, connection and white space when right-clicked. So far, I have not found a way to specify a Shape or Connection as the Target.  Can somebody suggest a solution?
Rumen
Telerik team
 answered on 28 Aug 2020
2 answers
198 views

Hi

I have a page with a radmultiselect. The items are populated using a webservice with the response in json format. All works fine.

I'm trying to get the items in code behind, but the RadMultiSelect.Items are aways null.

RadMultiSelect rms = area.FindControl("id_of_radmultiselect") as RadMultiSelect;
 
if (rms != null) {
    var selectedValues = rms.Value;
    foreach (string value in selectedValues) {
        MultiSelectItem selectedItem = rms.Items.FindChildByValue(value);
        string result = string.Format("Selected item with text: <strong>{0}</strong> and value: <strong>{1}</strong><br />", selectedItem.Text, selectedItem.Value);
    }
}

In my test I added two items and I get in the rms.Value the number 2.

But the rms.Items is always count = 0, and when I try to find chield by value the result are null.

Why the Value have two items and in the rms.Items is 0?

Thank you

Fabio PM
Top achievements
Rank 1
Iron
 answered on 28 Aug 2020
1 answer
140 views

Hi,

I need to set zoom level to 14,5 but when I use decimals, map location changes.

 

 

Figure 1 shows when zoom level is 14, then the place is correct

Figure 2 show when zoom level is set to 14,5 , then map is located in totally different place ???

 

Following map link is used to generate map:

https://#= subdomain #.tile.thunderforest.com/landscape/#= zoom #/#= x #/#= y #.png

 

- Auvo -

 

 

Doncho
Telerik team
 answered on 28 Aug 2020
1 answer
397 views

I have a combobox as filter in RadGrid. The combobox has "Alle"(all), "Nein"(no), "Ja"(yes) . The "Alle" was default. The page shows all 75 rows after loaded.

I want to have "Ja" as default and to show the 73 rows with "Ja". So I added OnLoad="cboFilterFormActive_Load" in the RadComboBox and a C# method cboFilterFormActive_Load(...).

The aspx code now is like:

<telerik:RadGrid ID="radGridForms" runat="server"
                 DataSourceID="SqlDataSource_Grid" AllowSorting="true" AllowPaging="true" PageSize="10" AllowFilteringByColumn="true"
                 OnDataBound="radGridForms_DataBound">
    <MasterTableView AutoGenerateColumns="false" AllowMultiColumnSorting="true">
        <CommandItemSettings ShowExportToExcelButton="true" ShowAddNewRecordButton="false" ShowRefreshButton="false" />
        <Columns>
            <telerik:GridTemplateColumn DataField="FormKey" UniqueName="FormKey">
            </telerik:GridTemplateColumn>
            <telerik:GridTemplateColumn DataField="visible" HeaderText="aktiv" UniqueName="FormActive">
                <FilterTemplate>
                    <telerik:RadComboBox ID="cboFilterFormActive" runat="server" RenderMode="Lightweight"
                                         Skin="Bootstrap" Width="100%" ToolTip="Filter Formular aktiv"
                                         DataSourceID="SqlDataSource_FilterFormActive" DataTextField="visible" DataValueField="visible"
                                         AppendDataBoundItems="false"
                                         SelectedValue='<%# ((GridItem)Container).OwnerTableView.GetColumn("FormActive").CurrentFilterValue %>'   
                                         OnClientSelectedIndexChanged="visibleComboIndexChanged"
                                         OnItemDataBound="cboFilterFormActive_ItemDataBound"
                                         OnLoad="cboFilterFormActive_Load">
                    </telerik:RadComboBox>
                    <telerik:RadScriptBlock ID="RadScriptBlockFilterVisible" runat="server">
                        <script type="text/javascript">
                            function visibleComboIndexChanged(sender, args) {
                                var tableView = $find("<%# ((GridItem)Container).OwnerTableView.ClientID %>");
                                tableView.filter("FormActive", args.get_item().get_value(), "EqualTo");
                            }
                        </script>
                    </telerik:RadScriptBlock>
                </FilterTemplate>
                <ItemTemplate>
                    <asp:Label ID="lblFormVisible" runat="server" Text='<%# translateBool(Eval("visible")) %>'></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
        </Columns>
        <PagerStyle Position="TopAndBottom" AlwaysVisible="true" />
    </MasterTableView>
    <SortingSettings SortedBackColor="#EDEDED" EnableSkinSortStyles="false"></SortingSettings>
    <FilterMenu Skin="Bootstrap" EnableEmbeddedSkins="false" RenderMode="Lightweight"></FilterMenu>
</telerik:RadGrid>

 

a new mothod in aspx.cs:

        protected void cboFilterFormActive_Load(object sender, EventArgs e)
        {
            var combo = (RadComboBox)sender;
            RadComboBoxItem itm = combo.FindItemByText("Ja");
            if (itm !=null)
                itm.Selected = true;
        }

 

The "Ja" is now default in the Combobox. But it doesn't filter. All the 75 values are shown after loading page. How can I make it filter "Ja" out?

Uli
Top achievements
Rank 1
Veteran
 answered on 28 Aug 2020
9 answers
787 views
Dear Support-Team,

is it possible to set the position of the RadContextMenu in the "OnClientShowing"-Event?
Even if it has been opened by right-click?
I want to show the ContextMenu on a defined position and need its width.
This is not possible with the ShowAt() Function because the width of the ContextMenu is not available.

To show the ContextMenu at the right side of a tablerow i would like to do something like this:

tmpTr is the clicked tr element.

contextMenu.showAt(tmpTr.position().left + tmpTr.width() - [CONTEXTMENUWIDTH], tmpTr.position().top + tmpTr.height());

regards, Robin
JeffSM
Top achievements
Rank 2
Iron
Veteran
Iron
 answered on 27 Aug 2020
6 answers
318 views

Upgraded UI for ASP.NET AJAX controls and OnClientBlur neverfires. Here is the markup:

<telerik:RadComboBox ID="radComboHansenClerks" CheckBoxes="true" AutoPostBack="false"
                        LabelCssClass="control-label" AllowCustomText="false" CloseDropDownOnBlur="true"
                        OnClientBlur="IsCheckAllSelected" CheckedItemsTexts="DisplayAllInInput" ShowDropDownOnTextboxClick="true"
                        runat="server" Filter="Contains" NoWrap="True" MaxHeight="400px" Width="100%"
                        AccessibilityMode="true" EnableCheckAllItemsCheckBox="true" Localization-CheckAllString="Select All"
                        OnItemChecked="radComboHansenClerks_ItemChecked">
                         
                    </telerik:RadCombo
function IsCheckAllSelected(sender, eventArgs) {                                              
              $('#<%= btnRadclerksFilter.ClientID %>').click();               
      }
Box>
Doncho
Telerik team
 answered on 27 Aug 2020
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?