Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
238 views
Greetings,

In my enterprise we have a WPF application, that runs a RadRichTextbox Editor. At the moment, we are migrating our system to web, refactoring all source to a MVC application.
To achieve the same aspects and features that our RadRichTextbox had, we implemented the Telerik RadEditor in ASP.NET.

The problem is that the old documments made on RadRichTextbox and saved as binary, aren't compatible with  the RadEditor in ASP.NET. 

I tried to convert the binary documments with WPF DLLs docxProvider generating a radflowdocument, and exporting to the editor that same radflowdocument with the HTML provider.  The result is an inevitable error that HTML provider doesn't support the binary that converted by the docxProvider from WPF.

I believe that the formats are completly differents and incompatibles, but we need some backward compatibility solution to display this old documents on our ASP.NET Telerik RadEditor.
 
Here is what we tried to do:


...

var binary = reportResp.Report.File; 
Telerik.Windows.Documents.FormatProviders.OpenXml.Docx docxProvider = new using Telerik.Windows.Documents.FormatProviders.OpenXml.Docx;

RadFlowDocument flowDocument = docxProvider.Import(binary); 
HtmlFormatProvider htmlProvider = new HtmlFormatProvider(); <--- From Telerik.Windows.Documents.Flow.dll
string result = htmlProvider.Export(flowDocument);  <----- error here -  flowDocument format not supported by htmlProvider

...
Petya
Telerik team
 answered on 28 Jan 2015
3 answers
239 views
How I can bind rad scheduler with dataset with out defined DataKeyField, DataSubjectField, DataStartField and DataEndField
actually very first these fields are not required in my case but for schedulefor its required databinding .
please help me how I can solve this problem
Boyan Dimitrov
Telerik team
 answered on 28 Jan 2015
44 answers
722 views
I have a RadCombox on my web page and it does not open in IE10.
Works fine in IE7,IE8 and IE9, Chrome.
I am using the latest version of ASP.NET AJAX controls, version 2012.3.1205.35.
The combo box is not ajaxed, although I do have other controls on the page that are ajaxed using RadAjaxManager.
Is there a setting I need to change or is this a known issue?

<telerik:RadComboBox runat="server" OnClientKeyPressing="ClickStartSearch" ID="rcbStatus" AccessKey="E" Width="200px" OnClientSelectedIndexChanged="RestartSearch" AutoPostBack="false" EnableAjaxSkinRendering="false" EnableEmbeddedScripts="false" MarkFirstMatch="false" >
   <Items>
    <telerik:RadComboBoxItem Text="Select Status" Value="" />
    <telerik:RadComboBoxItem Text="Status1" Value="1" />
    <telerik:RadComboBoxItem Text="Status2" Value="2"/>
    <telerik:RadComboBoxItem Text="Status3" Value="3" />
    <telerik:RadComboBoxItem Text="Status4" Value="4"/>
    <telerik:RadComboBoxItem Text="Status5" Value="5" />
    <telerik:RadComboBoxItem Text="Status6" Value="6" />
   </Items>
  </telerik:RadComboBox>
Miguel
Top achievements
Rank 1
 answered on 28 Jan 2015
1 answer
115 views
Hello ,
im Trying to use RadLightBox to show some pictures for different items so on click i need to change hidden field value and rebind the list .
so how can i rebind the light box from client side.

JS Code
function OpenImages(ItemID) {
$('#<%= hdnItemID.ClientID%>').val(ItemID);
//alert(ItemID);

var rlbItemImages = $find('<%= rlbItemImages.ClientID%>');
rlbItemImages.get_items();
//rlbItemImages.DataBind();
rlbItemImages.show();
}


RadLightBox Code
<telerik:RadLightBox ID="rlbItemImages" runat="server" DataSourceID="odsItemImages" ShowLoadingPanel="true"
EnableAjaxSkinRendering="true" RegisterWithScriptManager="true"
DataImageUrlField="ItemPath" DataDescriptionField="ItemPath" DataTitleField="ItemPath">
</telerik:RadLightBox>


Object DataSource Code

<asp:ObjectDataSource ID="odsItemImages" runat="server" SelectMethod="QueryDatabase" TypeName="AdoClass.DBitemsImagesSP" OldValuesParameterFormatString="original_{0}">
<SelectParameters>
<asp:Parameter DefaultValue="1" Name="QueryType" Type="Object" />
<asp:Parameter Name="ID" Type="String" />
<asp:ControlParameter ControlID="hdnItemID" Name="ItemID" PropertyName="Value" Type="String" />
<asp:Parameter DefaultValue="" Name="ItemImage" Type="Object" />
<asp:Parameter Name="ItemPath" Type="String" />
<asp:Parameter DefaultValue="rtvImagesPaths" Name="Operation" Type="String" />
</SelectParameters>
</asp:ObjectDataSource>
<asp:HiddenField runat="server" ID="hdnItemID" />

Regards ,

Maria Ilieva
Telerik team
 answered on 28 Jan 2015
1 answer
170 views
I have a RadNumericTextBox defined as follows:

<telerik:RadNumericTextBox ID="txtMaxCost" Runat="server" MaxLength="14" Width="250px"  Type="Currency" SkinID="OverrideRadDefaultSkinWithNonExistantSkin" AutoPostBack="true" Enabled="true" AllowOutOfRangeAutoCorrect="false">
<NumberFormat DecimalDigits="2" KeepNotRoundedValue="False"/>
</telerik:RadNumericTextBox>

When users enter a number that's out of range (e.g., 77777777777777), the text turns red and a yield sign appears in the control when focus is lost.  When the user saves the object, the control's value is set to null and therefore, our validation isn't executed on the code-behind.

I checked out the properties of the control and see there's an .Invalid property, but when I check it's state in the code, it's set to false.

How can I check to see that the control is in an invalid state programmatically?  
Viktor Tachev
Telerik team
 answered on 28 Jan 2015
5 answers
1.2K+ views
How to set the selected date of raddatepicker to asp parameter of an sql data source?
Kostadin
Telerik team
 answered on 28 Jan 2015
1 answer
66 views
I was trying to access data from AutoCompleteBox from the Private Sub RadAutoCompleteBox1_TextChanged(sender As Object, e As AutoCompleteTextEventArgs) Handles RadAutoCompleteBox1.TextChanged event.
I can get the text but I can't seem to get the DataValueField or any of the Data stored in the template fields (i.e., <%# DataBinder.Eval(Container.DataItem, "EMPTIN")%>)


RadAutoCompleteBox1.DataTextField = "ComboName"
RadAutoCompleteBox1.DataValueField = "EmployerIdnt"

<telerik:RadAutoCompleteBox ID="RadAutoCompleteBox1" runat="server" Width="400px" DropDownWidth="400px" EmptyMessage="Enter TIN or Name" TextSettings-SelectionMode="Single" inputtype="Text" >

<DropDownItemTemplate>

<table cellpadding="0" cellspacing="0">
<tr>
<td style="width: 25%">
Name:
</td>
<td style="width: 75%">
<%# DataBinder.Eval(Container.DataItem, "EMPNAME")%>
</td>
</tr>
<tr>
<td>
TIN:
</td>
<td>
<%# DataBinder.Eval(Container.DataItem, "EMPTIN")%>
</td>
</tr>
<tr>
<td>
City:
</td>
<td>
<%# DataBinder.Eval(Container.DataItem, "EMPCITY")%>
</td>
</tr>
<tr><td colspan="2"><hr /></td></tr>
</table>
</DropDownItemTemplate>

</telerik:RadAutoCompleteBox>

Thanks for any help
Henry
Boyan Dimitrov
Telerik team
 answered on 28 Jan 2015
4 answers
102 views
Hello everyone,
I'm configuring the RadEditor and I can't do these two things:
1) Node Inspector: customize the list of CSS classes visible in the dropdown "CLASSNAME" or hide the dropdown "CLASSNAME"
2) Toolbar: create a custom button to change the background color of the text

Thanks
Ianko
Telerik team
 answered on 28 Jan 2015
8 answers
2.1K+ views
i have RadTabStrip, with General and other tabs. there are input fields and save button on the general tab.

the purpose of the code bellow is to enable the general save button only when the user changed a value on general tab and don't allow him to continue to another tab if there is unsaved data.
the accomplish it:
1) $('#MainContent_RadPageViewGeneral :input').change(...
using this event I identify changes in any input and enable the save button
2) OnClientTabSelecting
using this event i identify when the user try to move to another tab, and block him in case he
didn't perform save (if the save button is enabled)

it's working beside in one case when the user enter the general tab, perform first change in a field and
then press on another tab without moving to another field inside this tab. in this case, change event isn't called, so the save
button didn't become enable and the user is allowed to move to another tab, even tough the field was modified.

how can i catch this event of modification on first time and pressing on another tab?

piece of code (.aspx):
<telerik:RadTabStrip ID="RadTabStripEditClaim" runat="server" MultiPageID="RadMultiPageEditClaim" SelectedIndex="0" OnClientTabSelecting="OnClientTabSelecting">
    <Tabs>
        <telerik:RadTab Text="General" Enabled="true" Value="General"></telerik:RadTab>
        <telerik:RadTab Text="Files" Enabled="true"  Value="Files"></telerik:RadTab>
    </Tabs>
</telerik:RadTabStrip>
  
<telerik:RadMultiPage ID="RadMultiPageEditClaim" runat="server" SelectedIndex="0" >
    <telerik:RadPageView ID="RadPageViewGeneral" runat="server">
        <fieldset>
        </fieldset>
    </telerik:RadPageView>
    ....
 </telerik:RadMultiPage>  
  
<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
        <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <%--load jquery library--%>
   <script type="text/javascript">
        $(document).ready(function () {
  
            //disable button <Save and Continue Update>
            $("#MainContent_ButtonSubmit").attr('disabled', 'disabled');
            $("#MainContent_ButtonSubmit").css({
                "cursor": "default",
                //"box-shadow": "none"
            });
          
            //in case the user perform changes in General tab
            $('#MainContent_RadPageViewGeneral :input').change(function () {
                //disable button <Save and Continue Update>
                $("#MainContent_ButtonSubmit").removeAttr('disabled');
                $("#MainContent_ButtonSubmit").css({
                    "cursor": "pointer",
                    //    "box-shadow": "1px 0px 6px #333"
                });
            });
          
        });
                      
         //client-side event occurs when the user selects a tab, before the tab is selected.
        function OnClientTabSelecting(sender, eventArgs) {
          
            var pageView = multiPage.get_selectedPageView();
            if (pageView.get_id() == 'MainContent_RadPageViewGeneral')
            {
                //we are exiting General tab
                //check status of save button, if not disabled then we need to save
                var disabledValue = $("#MainContent_ButtonSubmit").attr('disabled');
                if (disabledValue != 'disabled')
                {
                    alert('You cannot continue without performing save');
                    eventArgs.set_cancel(true); //stop the selection
                    return;
                }
            }
          
            eventArgs.set_cancel(false);
        }
  
     
    </script>
</telerik:RadCodeBlock>
Viktor Tachev
Telerik team
 answered on 28 Jan 2015
1 answer
68 views
We're using a RadToolTip.

The Tooltip is broken since the 2014.3.x build, it will only show on the first item. The rest of the items is just a "title" attribute without html rendering.

  <telerik:RadToolTip ID="rttGroepen" runat="server" TargetControlID="pnl" RelativeTo="Element" Text='<%# Eval("Omschrijving").ToString()  %>'
                    RenderInPageRoot="true" EnableShadow="false" AutoCloseDelay="0" CssClass="tooltip"
                    EnableAjaxSkinRendering="False" EnableEmbeddedBaseStylesheet="True" EnableEmbeddedSkins="False"
                    VisibleOnPageLoad="False" ViewStateMode="Disabled" ShowDelay="0" Overlay="True"
                    Position="TopCenter" HideDelay="2500">
                </telerik:RadToolTip>


What's the work-around for this, and does this get fixed in the next build?
Marin Bratanov
Telerik team
 answered on 28 Jan 2015
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?