Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
68 views
Hi there,

the value of the shape attribute isn't a well formed xhtml value. The radeditor writes an uppercased value into the shape attribute.

<area shape="RECT" coords="10,10,202,121" href="http://www.google.com" target="_blank" alt="no comment">

If you change the attributes value to a xhtml valid lowercased value, the Image Map Editor doesn't find the area.

Steps for reproducing that

1. Open this Url http://demos.telerik.com/aspnet-classic/editor/examples/ImageMap/DefaultCS.aspx
2. Add the following imagemap code into the editor.

<img style="width: 300px; height: 192px;" usemap="#rade_img_map_RadEditor1_0" src="/aspnet-classic/Editor/Img/UserDir/Marketing/banner.gif" id="Img1" border="0">
<map name="rade_img_map_RadEditor1_0" id="rade_img_map_RadEditor1_0">
<area shape="RECT" coords="10,10,202,121" href="http://www.google.com" target="_blank" alt="no comment">
<area shape="CIRCLE" coords="113,160,21" href="http://www.msdn.com" target="_blank" alt="no comment"></map>

This image map code is editable with the Image Map Editor
3. Change to html view

replace the uppercase "RECT" and "CIRCLE" shapes to "rect" and "circle" the imagemap will be well formed but you can't find the circle shape within the Image Map Editor.

Thanks and best regards
Uwe
Marin Bratanov
Telerik team
 answered on 06 Apr 2011
1 answer
123 views
I have a page that internally opens up a rad window.  On that rad window, it opens up a smaller rad window (to enter some options).  So Main Window opens Rad Window1 which opens Rad Window2.  When Rad Window2 times out, or encounters an error, I try and make a call to a javascript function on Main Window.  I thought I could do this using GetRadWindow.BrowserWindow.BrowserWindow.JSCall(), however, that is throwing the same error that GetRadWindow.BrowserWindow.JSCall() is throwing (JSCall is undefined).  Is there a way to make this call back to the Main Window from the second Rad Window opened?

Thanks,

Josh
Marin Bratanov
Telerik team
 answered on 06 Apr 2011
2 answers
250 views
Hi!  Is there a way to set a timeout for disabling a RadButton in the client-side?  I would like to disable a RadButton for 5 seconds after a user clicks on it. 

Here's the current code I have:
function DisableSubmitBtn() {
            var btnSubmit = $find('<% =btnItemSubmit.ClientId %>')
            btnSubmit.set_text("Submitting");
            btnSubmit.set_enabled(false)   
        }


I've tried using the window.setTimeout function but it doesn't seem to have any effect.  I have tried both:
setTimeout('document.getElementById("' + btnItemSubmit + '").disabled = false', 2000);
 
var btnSubmit = $find('<% =btnItemSubmit.ClientId %>')

setTimeout('btnSubmit.set_enabled(false)', 2000);


Thanks!
Amy
Top achievements
Rank 1
 answered on 06 Apr 2011
5 answers
163 views
Hello,

I'm new to this forum.  I see the Drag-and-Drop Row demo, I really like it.  I have a similar scenario where my first radgrid (doctorRadgrid) displays all the doctor names (using Linq binds from code behind), and the second radgrid (scheduleRadgrid) contains only doctor names that dragged from the first radgrid.  However, when a user drags a doctor name from doctorRadgrid to scheduleRadgrid, I don't want that doctor name deleted from the doctorRadgrid.  I just want it copy to the scheduleRadgrid.  Is that possible?  Can you please provide sample code, I really aprreciated your help.

Thanks in advance!
Maria Ilieva
Telerik team
 answered on 06 Apr 2011
1 answer
43 views
Hi, as per http://demos.telerik.com/aspnet-ajax/editor/examples/filemanagers/defaultcs.aspx, I have added the line to the web.config file and the entry for Document Manager to the Default.aspx file.

When I click the Document Manager button in the text editor, I always get nothing to choose, i.e., 'Page 1 of 0. Items 1 to 0 of 0'.

The RadEditor Default.aspx file is at e.g. F:/x/xx/xxx/xxxx/RadEditor.Net/Default.aspx and the documents folder is e.g. F:/Assets/Documents - what should I be entering in the line below?

Many thanks

<DocumentManager ViewPaths="~/Assets/Documents" UploadPaths="~/Assets/Documents" DeletePaths="Assets/Documents" />
Dobromir
Telerik team
 answered on 06 Apr 2011
1 answer
120 views

My structure is this... 
    MasterPage  >> Content Page which includes a RadGrid >> In the RadGrid, I am using a UserControl (ascx) for the insert item.

Masterpage has ScriptManager and RadAjaxManager
Contentpage has RadAjaxProxy
UserControl has RadAjaxProxy

The UserControl is basically a table with labels, Radtextboxes and Radcomboboxes.
My usercontrol has this declaration:
----------------------------------------------------------------------------

<telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server" >
    <AjaxSettings>
        <telerik:AjaxSetting AjaxControlID="uxDirectory">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="uxProjectName" />
            </UpdatedControls>
        </telerik:AjaxSetting>
    </AjaxSettings>

</telerik:RadAjaxManagerProxy>
-------------------------------------------------------------------------------
uxDirectory and uxProjectName are both RadComboBoxes

The problem I am facing is when a value is changed in the uxDirectory combobox all the  "Load" events based on other controls are being fired.  It is my understanding that since I have autopostback="true" on the uxDirectory, and based upon the declaration above, that only the uxProjectName control will Load.   However, all my controls are reloading.  This is wiping out the values saved, etc.  How can I perform a Ajax postback for a specific control within a ASCX Usercontrol?

-DB

Maria Ilieva
Telerik team
 answered on 06 Apr 2011
3 answers
256 views
All,

I am trying to do an insert/update of a numeric value. I have identical code in another control working just fine. All attempts to insert or update result in OriginalAmount being null. I have tried using a bound column and a numeric column with the same failure.

Any and all help is greatly appreciated. I cannot understand how this was working before and now does not, and another control with identical grid and code is fine.

Thanks,
Bruce

<telerik:RadGrid ID="RadGrid1" runat="server" AllowFilteringByColumn="True" AllowPaging="True"
    AllowSorting="True" AutoGenerateColumns="False" GridLines="None" OnInsertCommand="RadGrid1_InsertCommand"
    OnItemCommand="RadGrid1_ItemCommand" OnNeedDataSource="RadGrid1_NeedDataSource"
    OnUpdateCommand="RadGrid1_UpdateCommand" OnItemDataBound="RadGrid1_ItemDataBound"
    OnItemCreated="RadGrid1_ItemCreated" Width="100%">
    <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default">
    </HeaderContextMenu>
    <MasterTableView AllowMultiColumnSorting="True" CommandItemDisplay="Top" DataKeyNames="ID,OriginalAmount"
        CommandItemSettings-AddNewRecordText="Add new payment or credit"
        ClientDataKeyNames="ID" Font-Size="Smaller">
        <EditFormSettings>
            <EditColumn FilterControlAltText="Filter EditCommandColumn column">
            </EditColumn>
        </EditFormSettings>
        <PagerStyle Mode="NextPrevNumericAndAdvanced" />
        <CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings>
        <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
            <HeaderStyle Width="20px"></HeaderStyle>
        </RowIndicatorColumn>
        <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
            <HeaderStyle Width="20px"></HeaderStyle>
        </ExpandCollapseColumn>
        <Columns>
            <telerik:GridEditCommandColumn FilterControlAltText="Filter EditCommandColumn column"
                ButtonType="PushButton">
                <ItemStyle Font-Size="Smaller" Width="10%" />
            </telerik:GridEditCommandColumn>
            <telerik:GridButtonColumn CommandName="Rollback" ConfirmText="Are you sure you want to roll back the application of this payment/credit?"
                ConfirmTitle="Rollback?" FilterControlAltText="Filter Rollback column" Text="Rollback"
                UniqueName="Rollback" ButtonType="PushButton">
            </telerik:GridButtonColumn>
            <telerik:GridButtonColumn CommandName="Apply"
                FilterControlAltText="Filter Apply column" Text="Apply"
                UniqueName="Apply" ButtonType="PushButton">
            </telerik:GridButtonColumn>
            <telerik:GridButtonColumn CommandName="ViewApplication"
                FilterControlAltText="Filter View Application column" Text="View"
                UniqueName="ViewApplication" ButtonType="PushButton">
            </telerik:GridButtonColumn>
            <telerik:GridButtonColumn CommandName="NSF"
                FilterControlAltText="Filter NSF column" Text="NSF"
                UniqueName="NSF" ButtonType="PushButton">
            </telerik:GridButtonColumn>
            <telerik:GridDateTimeColumn DataField="CreditDate" DataType="System.DateTime" FilterControlAltText="Filter CreditDate column"
                HeaderText="Credit Date" UniqueName="CreditDate" DataFormatString="{0:MM/dd/yyyy}">
            </telerik:GridDateTimeColumn>
            <telerik:GridTemplateColumn DataField="ActivityTypeID" FilterControlAltText="Filter ActivityType column"
                HeaderText="Type" UniqueName="ActivityType">
                <EditItemTemplate>
                    <telerik:RadComboBox ID="rcbActivityType" runat="server">
                    </telerik:RadComboBox>
                </EditItemTemplate>
                <ItemTemplate>
                    <asp:Label ID="lblActivityType" runat="server" Text='<%# Eval("ActivityTypeID") %>'></asp:Label>
                </ItemTemplate>
            </telerik:GridTemplateColumn>
            <telerik:GridBoundColumn DataField="CreditIdentifier" FilterControlAltText="Filter Check Number column"
                HeaderText="Check Number" MaxLength="500" UniqueName="CreditIdentifier">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="OriginalAmount"
                FilterControlAltText="Filter OriginalAmount column"
                HeaderText="Original Amt." UniqueName="OriginalAmount"
                DataFormatString="{0:C2}">
            </telerik:GridBoundColumn>
 
            <telerik:GridNumericColumn DataField="RemainingAmount" DataType="System.Decimal"
                DecimalDigits="2" FilterControlAltText="Filter RemainingAmount column" HeaderText="Remaining Amt."
                NumericType="Currency" ReadOnly="True" UniqueName="RemainingAmount">
            </telerik:GridNumericColumn>
            <telerik:GridBoundColumn DataField="Notes" FilterControlAltText="Filter Notes column" ColumnEditorID="GridTextBoxColumnEditor1"
                HeaderText="Notes" MaxLength="500" UniqueName="Notes">
            </telerik:GridBoundColumn>
            <telerik:GridBoundColumn DataField="CreatedBy" FilterControlAltText="Filter CreatedBy column"
                HeaderText="Created By" MaxLength="50" ReadOnly="True"
                UniqueName="CreatedBy" Display="False">
            </telerik:GridBoundColumn>
 
 
        </Columns>
        <EditFormSettings>
            <EditColumn UniqueName="EditCommandColumn1" FilterControlAltText="Filter EditCommandColumn column" ButtonType="PushButton">
            </EditColumn>
        </EditFormSettings>
        <PagerStyle Mode="NextPrevNumericAndAdvanced"></PagerStyle>
    </MasterTableView>
    <FilterMenu EnableImageSprites="False">
    </FilterMenu>
</telerik:RadGrid>

protected void RadGrid1_UpdateCommand(object sender, Telerik.Web.UI.GridCommandEventArgs e)
{
    LaundryLogicDAL.ARCredits oARC = new LaundryLogicDAL.ARCredits();
 
    try
    {
        oARC.es.Connection.Name = "NAS";
        oARC.es.Connection.SqlAccessType = esSqlAccessType.DynamicSQL;
 
        GridEditableItem editedItem = e.Item as GridEditableItem;
        GridEditManager editMan = editedItem.EditManager;
 
        int iID = (int)editedItem.OwnerTableView.DataKeyValues[editedItem.ItemIndex]["ID"];
 
        DateTime dteCreditDate = DateTime.Parse((editMan.GetColumnEditor("CreditDate") as GridDateTimeColumnEditor).Text);
        int iActivityTypeID = Convert.ToInt16((editedItem["ActivityType"].FindControl("rcbActivityType") as RadComboBox).SelectedValue);
        decimal dOriginalAmount = CurrencyToDecimal((editMan.GetColumnEditor("OriginalAmount") as GridTextBoxColumnEditor).Text);
        string sNotes = (editMan.GetColumnEditor("Notes") as GridTextBoxColumnEditor).Text;
        string sCreditIdentifier = (editMan.GetColumnEditor("CreditIdentifier") as GridTextBoxColumnEditor).Text;
 
        if (oARC.LoadByPrimaryKey(iID))
        {
            oARC.CreditDate = dteCreditDate;
            oARC.ActivityTypeID = iActivityTypeID;
            oARC.CreditIdentifier = sCreditIdentifier;
            oARC.OriginalAmount = dOriginalAmount;
            oARC.Notes = sNotes;
            oARC.Save();
        }
    }
    catch (Exception ex)
    {
        DotNetNuke.Services.Exceptions.Exceptions.ProcessModuleLoadException(this, ex);
    }
    finally
    {
        oARC = null;
    }

Martin
Telerik team
 answered on 06 Apr 2011
2 answers
119 views
Hi guys

I've been customising the ToolsFIle.xml file successfully to reorder tools and toolbars.

When I try to use the ribbon feature by entering <tools name="MainToolbar" IsRibbon="true">, it makes no difference (despite the help at http://www.telerik.com/help/aspnet/editor/editoroffice2007ribbonbar.html).

Is this feature unavailable in the AJAX version of the text editor?

Neil
HWNeil
Top achievements
Rank 1
 answered on 06 Apr 2011
3 answers
159 views
How can I set imageurl for image column programatically?

Thanks, Patrick
Tsvetina
Telerik team
 answered on 06 Apr 2011
5 answers
414 views
Hi!

How can i activate the HoverStyle?, no matter what i do simple will not work
Anyone have a clue?

Thanks
JL

<telerik:RadScriptManager ID="RadScriptManager1" runat="server" />
                <!-- content start -->
                <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
                    <AjaxSettings>
                        <telerik:AjaxSetting AjaxControlID="grdMain">
                            <UpdatedControls>
                                <telerik:AjaxUpdatedControl ControlID="grdMain" />
                            </UpdatedControls>
                        </telerik:AjaxSetting>
                    </AjaxSettings>
                </telerik:RadAjaxManager>
                <telerik:RadGrid ID="grdMain" OnSortCommand="grdMain_SortCommand" OnPageIndexChanged="grdMain_PageIndexChanged"
                    Width="100%" OnPageSizeChanged="grdMain_PageSizeChanged" AllowSorting="True"
                    PageSize="20" AllowPaging="True" AllowMultiRowSelection="True" runat="server"
                    GridLines="None" Skin="Windows7" AutoGenerateColumns="true">
                    <MasterTableView Width="100%" Summary="RadGrid table"  />
                    <PagerStyle Mode="NextPrevAndNumeric" />                    
                    <ClientSettings AllowKeyboardNavigation="true" EnableRowHoverStyle="true">
                        <Selecting AllowRowSelect="true" />                        
                    </ClientSettings>
                </telerik:RadGrid>
                <!-- content end -->
Maria Ilieva
Telerik team
 answered on 06 Apr 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?