Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
1.0K+ views
I need to have a multiline textbox inside a radgrid cell.  I can get the multiline mode to work while in edit mode but when I leave edit mode the text is displayed without the line breaks.  I am using batch editmode if it matters.

Thanks

Here is my aspx code....
                                                                <telerik:GridTemplateColumn HeaderText="Test_Summary" HeaderStyle-Width="900px" 
                                                                    UniqueName="Test_Summary" DataField="Test_Summary"  ItemStyle-Wrap="true" ItemStyle-Height ="80px" >
                                                                    <HeaderStyle HorizontalAlign="Left" Width="900px" />
                                                                    <ItemStyle HorizontalAlign="Left" Width="900px" Height="80px"  VerticalAlign="Top"/>
                                                                <ItemTemplate>
                                                                    <%# Eval("Test_Summary")%>
                                                                </ItemTemplate>
                                                                <EditItemTemplate>
                                                                    <telerik:RadTextBox runat="server" ID="txtTestSummary"  DataTextField="Test_Summary" Width="900" Height="80"
                                                                        TextMode="MultiLine" >
                                                                     </telerik:RadTextBox>
                                                                 </EditItemTemplate>
                                                                 </telerik:GridTemplateColumn>




Rick
Top achievements
Rank 1
 answered on 23 Mar 2015
6 answers
144 views
Hi,

I am using the RadFileExplorer and this works fine but the user wants to add files to the folder by dragging them to the folder and drop it.  Not by first clicking the folder, then push the upload button and there drop (or select) the file and press upload. Too many steps...

Is there a way to do this?

Kind regards

Suzy
Sam
Top achievements
Rank 1
 answered on 23 Mar 2015
4 answers
388 views
I am attaching a web page screen shot including the developer tool.
When I highlight the RadWizard control in the DOM explorer, you can see the width shows "0px" (right hand column under "InLine style")
If I modify that width in the developer tool to 90% then the control expands as I would expect to fill the page.   Can you tell me how I can set that width specifically in the aspx page or the code behind so the control is not so narrow?  Hopefully bypass whatever other class/style that is causing this?
Patrick
Top achievements
Rank 1
 answered on 23 Mar 2015
8 answers
223 views
Hi,

I have a RadGrid wired up to an ObjectDataSource.

When I export with IgnorePaging set to False, it works fine, but only exports the current page of results (20 results).

When I export with IgnorePaging set to True, it exports the column headers, but no results.

How do I get it to return all the results from the ObjectDataSource?

Thanks,

Rob
Ahmed
Top achievements
Rank 1
 answered on 23 Mar 2015
2 answers
114 views
Hi,

I'd like to conditionally format data in a column series.

The demo for this that is in the demos section purports to being conditional formatting but it isn't.  It is actually simple series formatting.(http://demos.telerik.com/aspnet-ajax/htmlchart/examples/functionality/custombarcolor/defaultvb.aspx?show-source=true).  I don't want to have to have two series merged into one or to fiddle with the sql code.

I want to be able to do the following:
Value is above 90 colour the column green
Between 70 and 90 colour it orange
Below 70 colour it red

That is conditional formatting.  I am happy doing it in a data bound type event however there are no samples that I could see for this.  Please could one be generated and added to the demo lists.

Regards

Jon
Jon
Top achievements
Rank 1
 answered on 23 Mar 2015
3 answers
190 views
I have a grid where a user can right click on a row and a popup menu is displayed. Well I don't like right click functionality on a row in a webpage because it's not really standard UI behavior. I want to have the user click a button in the row to then show this same popup dialog.

I'm using a GridButtonColumn with the OnCommand.

So far I've not been able to get access to the get_DomEvent.

You can see in the javascript function I call that when I attempt to show the menu dialog that the "get_DomEvent" is
not a method that is available to me in the eventArgs. Is there some way I can get access to the get_DomEvent after
clicking on a button within the row of the grid?

Here is the code:

ASPX:
<Columns>
                            <telerik:GridTemplateColumn HeaderStyle-Width="5px"><ItemTemplate> </ItemTemplate></telerik:GridTemplateColumn>
                            <telerik:GridHyperLinkColumn HeaderStyle-Width="70px" DataTextField="CustomerNumber" DataNavigateUrlFields="CustomerNumber" DataNavigateUrlFormatString="~\Common\CustomerEdit.aspx?Customer={0}" HeaderText="Cust No." SortExpression="CustomerNumber" UniqueName="CustomerNumber" />
                            <telerik:GridHyperLinkColumn HeaderStyle-Width="300px" DataTextField="CustomerName" DataNavigateUrlFields="CustomerNumber" DataNavigateUrlFormatString="~\Common\CustomerEdit.aspx?Customer={0}" HeaderText="Name" SortExpression="CustomerName" UniqueName="CustomerName" />
                            <telerik:GridBoundColumn HeaderStyle-Width="125px" DataField="Address.City" HeaderText="City" SortExpression="Address.City" UniqueName="City" />
                            <telerik:GridBoundColumn HeaderStyle-Width="125px" DataField="Address.State" HeaderText="State" SortExpression="Address.State" UniqueName="State" />
                            <telerik:GridBoundColumn HeaderStyle-Width="75px" DataField="Address.ZipCode" HeaderText="ZipCode" SortExpression="Address.ZipCode" UniqueName="ZipCode" />
                            <telerik:GridBoundColumn HeaderStyle-Width="55px" DataField="Status" HeaderText="Status" SortExpression="Status" UniqueName="Status" />
                            <telerik:GridHyperLinkColumn HeaderStyle-Width="50px" DataNavigateUrlFields="CustomerNumber" DataNavigateUrlFormatString="~\Common\UserList.aspx?Customer={0}" HeaderText="Show" Text="Users" />
                            <telerik:GridHyperLinkColumn HeaderStyle-Width="50px" DataNavigateUrlFields="CustomerNumber" DataNavigateUrlFormatString="~\Returns\FilingEntityList.aspx?Customer={0}" Text="Entities" />
                            <telerik:GridButtonColumn ButtonType="PushButton" DataTextField="Status"  CommandName="CustomerRadGridUpdateStatusMenu" UniqueName="ChangeStatus" />
                        </Columns>
                        <PagerTemplate>
                            <vtx:GridPager ID="gridPagerControl" AddLabel="Add Customer" OnAddClicked="AddNewCustomerButton_Click" runat="server" />
                        </PagerTemplate>
                    </MasterTableView>
                    <ClientSettings>
                        <ClientEvents OnRowContextMenu="CustomerRadGridRowContextMenu"
                         OnCommand="CustomerRadGridUpdateStatusMenu"
                        />
                        <Selecting AllowRowSelect="True" />
                    </Client

JavaScript:
// Select row prior to context menu appearing
           function CustomerRadGridUpdateStatusMenu(sender, eventArgs)
           {
               // Get row index
               if (eventArgs.get_commandName() == "CustomerRadGridUpdateStatusMenu")
               {
                   var MasterTable = sender.get_masterTableView();
                   var index = eventArgs.get_commandArgument();
                   var row = MasterTable.get_dataItems()[index]; 
               }
 
               // Find row and select it
               sender.set_activeRow(row.get_element());
 
               // Fetch customer number   
               var columnCell =  MasterTable.getCellByColumnUniqueName(row, "CustomerNumber");
                 
 
               $get(clientID + 'customerNumberDisplay').innerHTML = columnCell.innerText;
               $get(clientID + 'customerNumberHidden').value = columnCell.innerText;
 
               // Fetch status
               columnCell = MasterTable.getCellByColumnUniqueName(row, "Status");
 
               $get(clientID + 'status' + columnCell.innerHTML).checked = true;
               $get(clientID + 'statusInactive').disabled = true;
               $get(clientID + 'statusActive').disabled = false;
               $get(clientID + 'statusDisabled').disabled = false;
               $get(clientID + 'statusDeleted').disabled = false;
                
               var menu = $find("<%= gridContextRadMenu.ClientID %>");
 
               if (columnCell.innerHTML == "Inactive")
               {
                   $get(clientID + 'statusActive').disabled = true;
                   $get(clientID + 'statusDisabled').disabled = true;
               }
 
               // Apply security as last option
               if (!allowDelete && !allowDisable)
               {
                   menu.findItemByValue("CS").disable();
               }
               else
               {
                   if (!allowDelete)
                   {
                       $get(clientID + 'statusDeleted').disabled = true;
                   }
 
                   if (!allowDisable)
                   {
                       $get(clientID + 'statusDisabled').disabled = true;
                   }
               }
 
               // Show menu
               var domEvent = eventArgs.get_domEvent();
               menu.show(domEvent);
 
               eventArgs.cancelBubble = true;
               eventArgs.returnValue = false;
 
               if (eventArgs.stopPropagation)
               {
                   eventArgs.stopPropagation();
                   eventArgs.preventDefault();
               }
           }

Marin
Telerik team
 answered on 23 Mar 2015
4 answers
355 views
Hey guys I have a page with a RadListView and have in it an ItemTemplate with a RadEditor.
As soon as I started to use a RadAjaxManager to be able to have a RadAjaxLoadingPanel, the page rendering was incorrect, the height of the RadPanes was very small and the custom buttons I did for the RadEditor crashed and began to display the following message:

The command CustomCommand is not implemented yet.

However I have implemented the Custom Commands immediately below the RadEditor's statement as follows:

...
</telerik:RadEditor>
<script type="text/javascript">
 //<![CDATA[
 //inserir imagens que fazem parte da lista de anexos
 Telerik.Web.UI.Editor.CommandList["ImageManager"] = function (commandName, editor, args) { ... some code ... };
 ...
 ...
 other custom commands
 ...
 ...
</script>

And all my RadPanes I set the Height="100%"

This text was translated from Portuguese into English by the translator google
Márcio
Top achievements
Rank 2
 answered on 23 Mar 2015
1 answer
89 views
Hello

We have a page (div) that represents an invoice.  The current export to pdf does a great job at exporting the invoice, however, there is a RadTab, in which tab 2 contains a list of parts.

Is it possible to include Tab 2 (which is not rendered on the page as it is not active) as an additional page to the same pdf.  If so, can you direct  or provide an example

Thanks in advance
Hristo Valyavicharski
Telerik team
 answered on 23 Mar 2015
1 answer
88 views
Two issues:

1) I am trying to export a radgrid to CSV. The button is configured to call back to C# and I see the code hit MasterTableView.ExportToCSV(), but I step over that line and nothing happens.
2) After hitting the export button and going through the code, the data in the table disappears.

ASP
<telerik:RadGrid ID="rgResources" runat="server" AutoGenerateColumns="false" ShowGroupPanel="false"
    OnPreRender="rgResources_PreRender1" OnColumnCreated="rgResources_ColumnCreated" OnItemCommand="rgResources_ItemCommand"
    GroupingEnabled="false" ShowFooter="true">
    <ClientSettings>
        <Selecting AllowRowSelect="false"></Selecting>
        <Scrolling AllowScroll="true" SaveScrollPosition="true" FrozenColumnsCount="2" UseStaticHeaders="true"
            ScrollHeight="150px"></Scrolling>
    </ClientSettings>
    <MasterTableView DataKeyNames="Resource" CommandItemDisplay="Top" AllowSorting="false"
        AutoGenerateColumns="true" ShowGroupFooter="true">
        <CommandItemSettings ShowExportToCsvButton="true" ShowAddNewRecordButton="false"  ShowRefreshButton="false" />
        <RowIndicatorColumn Visible="True" FilterControlAltText="Filter RowIndicator column">
        </RowIndicatorColumn>
        <ExpandCollapseColumn Visible="True" FilterControlAltText="Filter ExpandColumn column">
        </ExpandCollapseColumn>
    </MasterTableView>
    <ExportSettings IgnorePaging="true">
        <Csv FileExtension="CSV" />
    </ExportSettings>
    <FilterMenu EnableImageSprites="False">
    </FilterMenu>
    <ClientSettings EnableRowHoverStyle="true">
    </ClientSettings>
</telerik:RadGrid>

C#
protected void rgResources_ItemCommand(object sender, Telerik.Web.UI.GridCommandEventArgs e)
{
    if (e.CommandName == Telerik.Web.UI.RadGrid.ExportToCsvCommandName)
    {
        rgResources.MasterTableView.ExportToCSV();
    }
}

I'm very new to this so I'm sure I'm missing something obvious but could use some help being pointed in the right direction.

Thanks
Konstantin Dikov
Telerik team
 answered on 23 Mar 2015
3 answers
174 views
On the demos page for the Q2 2012 release,there is a demo called 'telerik Image Gallery.'  Is there any sample source code or documentation regarding this demo available?
Thanks
Konstantin Dikov
Telerik team
 answered on 23 Mar 2015
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
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
Iron
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?