Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
132 views
How do i get the values from a grid when i have multiple rows selected?

I am using datakeynames in my grid and if i was to retrieve one row i'd use the following:

radgrid1.selectedvalue

I have tried using radgrid1.selectedvalues but don't appear to be getting anywhere - I can only see one value being returned no matter what i use - hashtable, arrary etc.

Please help

Thanks

Princy
Top achievements
Rank 2
 answered on 20 Dec 2010
5 answers
262 views
I've got a hierarchical grid bound to a dataset with AutoGenerateHierarchy set to true.I'm setting the column widths in the OnColumnCreated event handler by setting HeaderStyle.Width. ( note that tablelayout is set to fixed). so that the columns in each level of the hierarchy align.

This works fine except when there are fewer columns than needed to fill the width. In this case IE8, all the columns on each level of the hierarchy stretch to the page width and align (which isn't really the expected behaviour as I'm setting a fixed width, but looks ok as they align), whereas in the case of IE7 the columns in the master table stretch to the page width but the columns in the detail tables are rendering as the fixed width I have assigned programatically so master and detail columns are not aligning.

I need either all the columns to stretch and align in IE7 or (preferably) all the columns to render as the asigned fixed width on both master and detail tables in both IE7 and IE8. Any Suggestions?

Thanks in advance :)
Pavlina
Telerik team
 answered on 20 Dec 2010
1 answer
187 views
Hi,

I have using Radgrid Export to PDF option. i have four columns in my radgrid. i am using linkbutton in my grid. but all record download but linkbutton column not showing in PDF. i am using in aspx page in this code.

<ExportSettings ExportOnlyData="true" IgnorePaging="True" OpenInNewWindow="true" >
                                <Pdf FontType="Subset" PaperSize="Letter" PageTitle="Employee Password List"  />
                                <Excel Format="Html"  />
                                <Csv RowDelimiter="NewLine" FileExtension="Csv"/>
                            </ExportSettings>
                            <PagerStyle Mode="NextPrevNumericAndAdvanced" />

and vb page

If e.ExportType = ExportType.Pdf Then
            dgPortalUsers.ExportSettings.IgnorePaging = True
            dgPortalUsers.ExportSettings.OpenInNewWindow = True
            dgPortalUsers.ExportSettings.ExportOnlyData = True
            e.ExportOutput = Replace(e.ExportType, "<br/>", "")
        End If

I have three doubts in this page

1. How to display linkbutton(Text) in PDF and Excel
2. How to hide Filter option what we enter some text.
3. How to restrict particular row in this grid. like name=John means we need to download without this row.


I have attached images also. Please check and help me ASAP.

Thanks in Advance,
Dhamu.
Princy
Top achievements
Rank 2
 answered on 20 Dec 2010
3 answers
110 views
We're using Telerik.Web.UI 2008.2.826.20 and have a RadRotator on our page to cycle among 20 cartoon images. We're using the FromCode rotator type. Both our ID on the control AND our CssClass are set to "rotCartoons". Below is our JavaScript code:

    Sys.Application.add_load(function(){
    
        jQuery(function($){
            var rotator = $find($(".rotCartoons").attr("id"));
           
            $("a[href=#cartoon-previous]").click(function(e){
                e.preventDefault();
                rotator.showNext(Telerik.Web.UI.RotatorScrollDirection.Right);
               
            });
           
            $("a[href=#cartoon-next]").click(function(e){
                e.preventDefault();
                rotator.showNext(Telerik.Web.UI.RotatorScrollDirection.Left);
            });
        })
    
    });

It basically binds jQuery click handlers to to left and right anchors. On each click, it gets the rotator in JS and calls showNext() in the correct direction. When we load the page nothing happens as expected. Once we hit either the Previous or Next button, showNext() is called in the respective direction and it slides in the next cartoon, then a few seconds later it goes again to the next, etc.. How do we prevent it from auto-rotating to the next cartoon?

Thanks in advance,
Mark
Fiko
Telerik team
 answered on 20 Dec 2010
1 answer
165 views
Version: Telerik.Web.UI (2009.2.701.20)

Hallo,

we are using the ComboxBox to show a selecting of persons in our company.
All persons have a status (activ, deactiv, deleted)  we show in an icon in the ImageUrl Property of the ComboBox Icon.

After we load the data to the ComboBox all icons are shown the status of the persons (to do this we use telerik help article).
And we use the autocomplete function of the ComboxBox so that that the users of your application can select person by searchstring.
The autocomplete result dropdownlist shows the person find by the searchstring but no icons are show in this list.

So the question is, if it is possible to see also the item icons in the autocomplete dropdownlist of the ComboBox.

Thank you and Merry Christmas and Happy New Year from Berlin
Torsten Baumelt
Dimitar Terziev
Telerik team
 answered on 20 Dec 2010
3 answers
99 views
Hi. This isn't a Telerik specific question but I do want to implement the solution with Telerik controls where possible and appropriate. I just wondered whether anyone could offer any initial comments or guidance.

I have external users for a site that I am developing and they can create photo albums and upload photos. I would appreciate any comments about how best to implement this. In particular:

- I assumed that all photos would be uploaded under a single folder (?) but should each user effectively have their own directory or should I just put all photos (potentially a large number) in one directory

- I had considered renaming files on upload and just creating a guid which I convert to a string and use as the filename on the server. I was then going to have a database table to record which user "own" the photo and the photo's filename. A further table can then create "virtual photo album" (ie have fields for album name, user...). The first table can have an additional field that allocates the photo to an album.

- Is there a way to resize .jpg files on upload?

- Are there any code examples here that show something similar to the above.

Dobromir
Telerik team
 answered on 20 Dec 2010
1 answer
50 views
Hi  to all Teleriks!!!
Here i attach one image its show like flash content, but i need to to do in Rad Chart animated, if i have Three parts

  1. Fat
  2. Cals
  3. Portin
if i click Fat area the area will be focused and separate from the chart like Explode Pie chart

Thanks in advancE
       vinoth X 
Evgeni "Zammy" Petrov
Telerik team
 answered on 20 Dec 2010
5 answers
88 views
Hello guys,

After some problems with the upgrade from radeditor 4.4 to 5.7.1, the editor is finally in place and the reusable content is working.(it can update the content automatically). But I've encountrered with another issue now.
I've a site, which requieres authentication and in it, the reusable content seems to work fine. But in the extended site which allow anonymous access, the reusable content is not visible. This issue could be reproduced in both live and test environment, but not in the development environment.

The reusable content is approved, the NT AUTHORITY\authenticated users has read access to it. But the reusable content is still not visible for the visitors in the extended site. What could I possible be missing? Server configuration? Some other permisson for the visitors? Or is it a bug?

Best regards, Daniel
Stanimir
Telerik team
 answered on 20 Dec 2010
1 answer
141 views
I have used the ITemplate structure to dynamically create columns for RadGrid's -- and it works great for me for display purposes.

I am now trying to add a LinkButton and to process the event when it's clicked through the Grid's onItemCommand property.  Although, when the linkbutton is clicked, the page postback happends, but the ItemCommand method is not triggered.

What's the missing link?

Thanks,
Todd.

grid html

<telerik:RadGrid ID="TimeSlotScheduleGrid" runat="server" EnableViewState="True"
      AutoGenerateColumns="False" Width="584" ShowFooter="false"
      onItemDataBound="TimeSlotScheduleGrid_RowDataBound" onItemCommand="TimeSlotScheduleGrid_RowCommand"
      OnColumnCreated="TimeSlotScheduleGrid_ColumnCreated">                     
      <MasterTableView DataKeyNames="Id"  GroupLoadMode="Client" Width="99%">
          <GroupByExpressions>
              <telerik:GridGroupByExpression>
                  <SelectFields>
                      <telerik:GridGroupByField FieldName="GameNo" HeaderText="Game Number" HeaderValueSeparator=": " />
                  </SelectFields>
                  <GroupByFields>                                    
                      <telerik:GridGroupByField FieldName="GameNo" SortOrder="Ascending" />
                  </GroupByFields>
              </telerik:GridGroupByExpression>
          </GroupByExpressions>                      
      <Columns>                                
          <telerik:GridTemplateColumn HeaderText='Time Slot'>
              <HeaderStyle Width="130" />
              <ItemStyle  HorizontalAlign="Left" VerticalAlign="Middle" />                    
              <ItemTemplate>                                
                      <asp:Label ID="timeSlotLabel" runat="server" />                                
              </ItemTemplate>
          </telerik:GridTemplateColumn>                                                            
      </Columns>
      </MasterTableView>
      <ClientSettings EnableRowHoverStyle="false">
          <Selecting AllowRowSelect="false" />
          <Scrolling AllowScroll="True" UseStaticHeaders="True" SaveScrollPosition="True" FrozenColumnsCount="1"/>                        
      </ClientSettings>                     
  </telerik:RadGrid>

The columns are created during the first Page_Load

for (int wk = 1; wk < (maxWeeks + 1); wk++)
{
    GridTemplateColumn templateColumn = new GridTemplateColumn();
    string columnName = "W" + wk.ToString();
    templateColumn.HeaderText = columnName;
    templateColumn.HeaderStyle.Width = new Unit(40);
    templateColumn.UniqueName = columnName;
    templateColumn.ItemStyle.HorizontalAlign = HorizontalAlign.Center;
    templateColumn.ItemStyle.VerticalAlign = VerticalAlign.Top;
      
    if(divisionObj.IsManualTimeSlotEntry)
        templateColumn.ItemTemplate = new TimeSlotCheckBoxTemplate(columnName);
    else
        templateColumn.ItemTemplate = new TimeSlotTemplate(columnName);
    TimeSlotScheduleGrid.MasterTableView.Columns.Add(templateColumn);
}

Here is the template class

private class TimeSlotTemplate : ITemplate
{
    private string templateName;
    //controls
    private Label label;
    private LinkButton linkButton;
    private Image image;
      
    public TimeSlotTemplate(string name)
    {
        templateName = name;
    }
    public void InstantiateIn(System.Web.UI.Control container)
    {
        label = new Label();
        label.ID = templateName +  "Label";
        linkButton = new LinkButton();
        linkButton.ID = templateName + "Button";
        image = new Image();
        image.ID = templateName + "Image";
        linkButton.Controls.Add(image);
        container.Controls.Add(label);
        container.Controls.Add(linkButton);
    }
}


Princy
Top achievements
Rank 2
 answered on 20 Dec 2010
1 answer
64 views
Hello,

I see how to set DayStartTime and DayEndTime for DayViewDefinition, WeekViewDef...etc.

However, is it possible to have the scheduler's day span from 6am to 6am the next day for all views (ie. day, week, month) rather than cutting off at 12am?

Thanks!
Peter
Telerik team
 answered on 20 Dec 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?