Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
164 views
Hi,

I just wanted to ask when the Prometheus Editor will be released as a Sharepoint Feature.
Or did this already happen and I missed it?

Kind regards

Martin
George
Telerik team
 answered on 19 May 2008
3 answers
192 views
Hi, I am attempting to add a class attribute to the unorderedlist HTML within the editor.  So aiming for HTML markup of
"<ul class='contentbullets' ><li>&nbsp;</li></ul>"

I am using the following below where I never enter the callBackFnUL.

var insertUnorderedListCommand = RadEditorCommandList["InsertUnorderedList"]; 
RadEditorCommandList["InsertUnorderedList"] = function(commandName, editor, oTool) 
{      
    insertUnorderedListCommand (commandName, editor, callBackFnUL);  
     
    function callBackFnUL(result)  
    {  
        if (result)  
        {  
            editor.PasteHtml("<ul class='contentbullets' ><li>&nbsp;</li></ul>"); 
        };  
    } 
 
} 

If i change the code to, see below, then the desired HTML markup is achieved.  However, two parts of HTML are added.  1.  The default HTML generated by the editor at the correct text insert point.  2.  My desired HTML markup but this is placed at the end of the editor's content.
var insertUnorderedListCommand = RadEditorCommandList["InsertUnorderedList"]; 
RadEditorCommandList["InsertUnorderedList"] = function(commandName, editor, oTool) 
{      
    insertUnorderedListCommand (commandName, editor, callBackFnUL);  
    editor.PasteHtml("<ul class='contentbullets' ><li>&nbsp;</li></ul>"); 
} 

Does anyone know how to achieve adding a class attribute to the unorderedlist HTML within the editor? 

Many thanks.  Scott.

Rumen
Telerik team
 answered on 19 May 2008
1 answer
140 views

 

Hi,

I have replaced the rad prometheus grid to new telerik (ASPNETAJAX grid) but it is giving me error in the below code.

Please assist.

private void insertRecord(GridCommandEventArgs e)

{

string args = string.Empty;

// Get the Exam Id

if (e.Item.OwnerTableView.Name == "Detractions")

{

GridDataItem parentExam = e.Item.OwnerTableView.ParentItem;

args = string.Format("\"Detractions/Edit.aspx?eid={0}\", \"DetractionDialog\"",

parentExam.OwnerTableView.DataKeyValues[parentExam.ItemIndex]["ID"].ToString());

}

else

{

args = "\"Edit.aspx\", \"ExamDialog\"";

}

// Create the script to open the editor window

 grdExams.ResponseScripts.Clear();//error  grdExams.ResponseScripts.Add(string.Format("window.radopen({0});", args)); //error

}

//Error

'Telerik.Web.UI.RadGrid' does not contain a definition for 'ResponseScripts' and no extension method 'ResponseScripts' accepting a first argument of type 'Telerik.Web.UI.RadGrid' could be found (are you missing a using directive or an assembly reference?) 

Thanks
vivek

Vlad
Telerik team
 answered on 19 May 2008
1 answer
131 views

Is it just me, or does anyone think it would be nice if you had access to the old value of the Text property as well as the new one in the Serverside TextChanged event?

-- 

Stuart

Dan
Top achievements
Rank 1
 answered on 19 May 2008
4 answers
156 views
Hi,

Can you disable dates prior todays date?  I dont wan the user being able to backdate a record.  Is this possible?

Thanks,

JK
JK
Top achievements
Rank 1
 answered on 19 May 2008
0 answers
123 views
Dear All,

I am implementing a dynamic change of the site theme.
My point is that; 
If I need to create/have custom images and those to be loaded according to the current selected theme for any RadControl that support images like Menu/Grid/ etc .... and if this control is placed inside User Control

How can I assign these Images to RadControls in this case.

I tried for RadMenu to do this:
ClickedImageUrl="App_Themes/<%= Page.Theme %>/Menu/Img/arrow.gif"

But it isn't working ...

Any Ideas
Best regards
Waleed
Waleed Seada
Top achievements
Rank 2
 asked on 19 May 2008
1 answer
104 views
I have a DataTable that is pivoted.  I would like to be able to retrieve the associated ID for an item within a particular cell.  Since the Data is pivoted once it's attached to the RadView, the ID fields show up in a column, rather than with each individual field.  Is it possible to retrieve this from the grid?  I should note also that I am using dynamically created template columns.

Within my template column I am including a popup extender control and wish to set the behavior id to the unique id of the field being bound.
Princy
Top achievements
Rank 2
 answered on 19 May 2008
1 answer
166 views
I'm having trouble understanding just how to use the selected value of a Combobox to display the correct data in a grid.


I have worked through this example but still my code is missing something:

http://www.telerik.com/DEMOS/ASPNET/Prometheus/Controls/Examples/Integration/GridComboAjax/DefaultCS.aspx?product=grid


It only works if I define a default value in the SQLDataSource's wizard.

Any ideas?

Here is my code:

                <telerik:radcombobox id="cboTime" runat="server" skin="Vista" DataSourceID="SqlTime"  DataTextField="sTimeId" AutoPostBack="True">  
                    <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation> 
                </telerik:radcombobox>    
 
 
    <telerik:RadGrid ID="grdGrid" runat="server" DataSourceID="Sqlgrid" GridLines="None" Skin="Vista" AllowSorting="True" AllowPaging="True">  
        <MasterTableView DataSourceID="Sqlgrid">  
            <RowIndicatorColumn Visible="False">  
                <HeaderStyle Width="20px" /> 
            </RowIndicatorColumn> 
            <ExpandCollapseColumn Resizable="False" Visible="False">  
                <HeaderStyle Width="20px" /> 
            </ExpandCollapseColumn> 
            <EditFormSettings> 
                <PopUpSettings ScrollBars="None" /> 
            </EditFormSettings> 
        </MasterTableView> 
        <ClientSettings> 
            <Selecting AllowRowSelect="True" /> 
        </ClientSettings> 
    </telerik:RadGrid> 
 
    <asp:SqlDataSource ID="Sqlgrid" runat="server" ConnectionString="<%$ ConnectionStrings:MyDbConnectionString %>" 
        SelectCommand="Get_TimeTest" SelectCommandType="StoredProcedure">  
        <SelectParameters> 
            <asp:ControlParameter ControlID="cboTime" Direction="InputOutput" 
                Name="sTimeId" PropertyName="SelectedValue" Type="String" /> 
        </SelectParameters> 
    </asp:SqlDataSource> 
 
    <asp:SqlDataSource id="SqlTime" runat="server" SelectCommand="SELECT [sTimeId] FROM [Times]"   
    ConnectionString="<%$ ConnectionStrings:MyDBConnectionString2 %>">  
    </asp:SqlDataSource>      
</asp:Content> 

Sebastian
Telerik team
 answered on 19 May 2008
3 answers
120 views
I am trying to perform some simple data validation of the nodes on client-side editing. The purpose is to disallow two items with the same parent and matching names. I handle OnClientNodeEditing and, if the validation fails, call startEdit() of the edited node.
function RadTreeView1_OnClientNodeEditing(sender, eventArgs) 
{ 
    var node = eventArgs.get_node(); 
    var oldText = node.get_text(); 
    var newText = eventArgs.get_newText(); 
    var siblings = node.get_parent().get_nodes(); 
 
    for(i = 0; i < siblings.get_count(); i++) 
    { 
        var currNode = siblings.getNode(i); 
        if(currNode != node && currNode.get_text() == newText) 
        { 
            alert('A folder with the given name already exists.'); 
            node.set_text(oldText); 
            node.startEdit(); 
            eventArgs.set_cancel(true); 
            return; 
        } 
    } 
    node.set_text(newText); 
    node.set_postBack(true); 
}            
Calling startEdit() shows an edit element on top of the node, looking like a standard EditBox element, not the usual behavior when editing a node. Apart from that, the text in that edit box is selected and can be edited, but pressing Enter or clicking outside the node doesn't cancel edit mode, but does its normal behavior (for example, if clicking on another node, its NodeClick event is fired). Keyboard focus is also not in that edit box element, but on the tree, so pressing the arrow keys navigates trough the nodes instead of moving the cursor inside the edit box.
If I try to end edit mode with node.endEdit() before starting startEdit() again, it throws a null reference error.
Simon
Telerik team
 answered on 19 May 2008
1 answer
150 views
Hi Guys,
 
      I have 2 dropdowns in a radgrid that are displayed when the grid is in edit mode. Dropdown1 is populated with data and dropdown2 is disabled with one value, "Please select from dropdown1 first". When the user selects from dropdown1, I want to populate dropdown2 based on the dropdown1 selection. I have attached a server side OnIndexChange event to dropdown1 but on postback, the grid does not come back in edit mode. Is my best option to create a client event for dropdown1 that calls a webservice to populate dropdown2. If yes, do you have an example of how to populate a dropdown or a combo box using the webservice manager? What is the proper approach here?

Thanks,
Jayvr
Iana Tsolova
Telerik team
 answered on 19 May 2008
Narrow your results
Selected tags
Tags
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?