Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
162 views
Please let me know why am i not able to access GridImageColumn though i have added "Telerik.web.ui" reference and imported it in my file.


Thanks a million in advance.
Shinu
Top achievements
Rank 2
 answered on 07 Aug 2009
2 answers
63 views
Hi,

         Am using the Telerik radgridview for my application. And i have set Post back to true...If i need Paging and sorting to be done for my gridview, its getting disappeared. So how can i set Paging and Posting in a grid view if Post back is set.

Thanks & Regards,
Vijayaragavan R
Vijayaragavan
Top achievements
Rank 1
 answered on 07 Aug 2009
1 answer
193 views
Can someone help me with this? When I right-click on a grid row to bring up my context menu, the row that I right-click on does not get selected. Is there a way to get the row selected when I right click on it?
Shinu
Top achievements
Rank 2
 answered on 07 Aug 2009
19 answers
1.2K+ views

I am opening a RadWindow from within RadWindow as per the examle.

The second radWindow opens up fine, but it opens in the background of the first window. I have to click on the second window then it comes up on the top.

I tried using setActive, setVisible, show - but none of them make the second window on top of first.

Any idea?
-Piyush
DW Web Team Member
Top achievements
Rank 2
 answered on 07 Aug 2009
9 answers
740 views
Hi,

I have a grid with 3 columns:
Column 1 - an editable GridDateTimeColumn which displays and accepts a date
Column 2 - an editable GridBoundColumn (with GridTextBoxColumnEditor) which displays and accepts a string
Column 3 - a GridEditCommandColumn

In edit mode, I would like to do the following:
Column 1 - to force the user to select the date from the DatePicker only (i.e. to disable the text box)
Column 2 - to restrict the length of the string which can be entered by the user to 60

Can you please show me how to do these?
Can you please also show me how to set the width of the GridTextBoxColumnEditor from the code behind instead of from ASPX?

The web page is available on http://www.gouw.ws/RadGrid

The code is given below:
ASPX
====
<form id="form1" runat="server">
<div>
    <telerik:RadScriptManager ID="radScriptManager" runat="server" />
    <telerik:RadGrid ID="radGrid" AutoGenerateColumns="false" GridLines="Vertical" OnNeedDataSource="radGrid_NeedDataSource" OnUpdateCommand="radGrid_UpdateCommand" runat="server">
        <ClientSettings>
            <Scrolling UseStaticHeaders="true" />
        </ClientSettings>
        <MasterTableView EditMode="InPlace" TableLayout="Fixed">
            <Columns>
                <telerik:GridDateTimeColumn DataField="Date" PickerType="DatePicker" DataFormatString="{0:dd/MM/yyyy}" DataType="System.DateTime" HeaderText="Date" HeaderStyle-HorizontalAlign="Left" HeaderStyle-Width="13%" ItemStyle-HorizontalAlign="Left" UniqueName="Date" />
                <telerik:GridBoundColumn DataField="Description" ColumnEditorID="gridTextBoxColumnEditor" DataType="System.String" HeaderText="Description" HeaderStyle-HorizontalAlign="Left" HeaderStyle-Width="77%" ItemStyle-HorizontalAlign="Left" UniqueName="Description" />
                <telerik:GridEditCommandColumn ButtonType="LinkButton" HeaderStyle-Width="10%" UniqueName="Edit" />
            </Columns>
        </MasterTableView>
    </telerik:RadGrid>

    <telerik:GridTextBoxColumnEditor ID="gridTextBoxColumnEditor" TextBoxStyle-Width="920px" runat="server" />
</div>
</form>

C#
==
public partial class Default : System.Web.UI.Page
{
    private List<Datum> _data = null;

    protected void Page_Load(object sender, EventArgs e)
    {
        if (IsPostBack)
        {
            this._data = (List<Datum>)Session["DATA"];
        }
        else
        {
            this._data = Datum.Load();
            Session["DATA"] = this._data;
        }
    }

    protected void radGrid_NeedDataSource(object source, GridNeedDataSourceEventArgs e)
    {
        this.radGrid.DataSource = this._data;
    }

    protected void radGrid_UpdateCommand(object sender, GridCommandEventArgs e)
    {
        if (e.Item is GridEditableItem && e.Item.IsInEditMode)
        {
            GridEditableItem item = e.Item as GridEditableItem;
            ((Datum)(this._data[item.ItemIndex])).Date = ((RadDatePicker)item["Date"].Controls[0]).SelectedDate.Value.Date;
            ((Datum)(this._data[item.ItemIndex])).Description = ((TextBox)item["Description"].Controls[0]).Text;
        }
    }
}

public class Datum
{
    public DateTime Date { get; set; }
    public string Description { get; set; }

    public Datum(DateTime date, string description)
    {
     Date = date;
     Description = description;
    }

    public static List<Datum> Load()
    {
     List<Datum> data = new List<Datum>();
        data.Add(new Datum(DateTime.Now, "This date is today"));
        data.Add(new Datum(DateTime.Now.AddDays(1), "This date is tomorrow"));
        data.Add(new Datum(DateTime.Now.AddDays(2), "This date is the day after tomorrow"));
        return data;
    }
}

Thanks &  regards,
Herman Gouw
Skype: hermangouw
Herman Gouw
Top achievements
Rank 1
 answered on 06 Aug 2009
2 answers
486 views
Hi I've built a ASP.NET user control (ascx) with a radgrid in it.
The control is placed on a ASPX page. When a user click on a row in the radgrid
 
When a user click on the radgrid in the ASCX I want to do an ajax update of a couple of graphs on the ASPX page. 

What's the best way to get the event in the ascx to the aspx page and update the controls based on the current selection in the grid?

Thanks!
Mike
Top achievements
Rank 1
 answered on 06 Aug 2009
2 answers
173 views
I am trying to update the time in timepicker when the time is selected. However, when i try to update the time, the OnDateSelected handler is called, causing an infinite loop. How can I disable the event handler temporarily so I can update the time?


<telerik:RadTimePicker ID="uxStartTime" runat="server" Skin="Default" TimeView-RenderDirection="Horizontal" 
                                                        Width="85px" ClientEvents-OnDateSelected="dateSelected" TimeView-Interval="0:30" 
                                                        TimeView-Columns="4" EnableTyping="false" /> 

function dateSelected(sender, eventArgs) 
        { 
            var endTime = sender.get_selectedDate(); 
            endTime.setMinutes(endTime.getMinutes() + 10); 
            sender.set_selectedDate(endTime); 
        } 

Ron Cirka
Top achievements
Rank 1
 answered on 06 Aug 2009
8 answers
318 views
Hi,

I am trying to show filtering menu onMouseOver even of the Filter button and to hide the menu onMouseOut event if the user decides not to change the filtering option. I managed to show the menu and have the problem with hidding it. Do you have any suggestion how I can do it?

Here is my code:

using

 

System.Web.UI.WebControls;

 

using

 

Telerik.Web.UI;

 

namespace

 

WWR.Common.UI.WebControls

 

{

 

public class WWRFilteringGridBoundColumn : GridBoundColumn

 

{

 

public WWRFilteringGridBoundColumn() : base()

 

{

AutoPostBackOnFilter =

true;

 

}

 

protected override void SetupFilterControls(TableCell cell)

 

{

 

base.SetupFilterControls(cell);

 

TextBox txtFilter = (TextBox)cell.Controls[0];

txtFilter.Attributes.Add(

"onclick", "javascript:document.getElementById('" + txtFilter.ClientID + "').select();document.getElementById('" + txtFilter.ClientID + "').focus();");

 

Button btnFilter = (Button)cell.Controls[1];

btnFilter.Attributes.Add(

"onmouseover", "javascript:document.getElementById('" + btnFilter.ClientID + "').click()");

 

 

//btnFilter.Attributes.Add("onmouseout", "javascript: ");

 

}

}

}

Thank you for advance,

Tatiana

Mira
Telerik team
 answered on 06 Aug 2009
9 answers
118 views
We have been using Telerik RadEditor since 1997 we are using version 4.4.1.0.  When I try to edit a page all of the icons are gone.  It just shows text for the buttons and when I try to use the MOSS Link Manager I get the following error :Could not find the command MOSSLinkManager.  Please update your command list.  I have no idea how to fix this.  Any ideas?
gail kinney
Top achievements
Rank 1
 answered on 06 Aug 2009
2 answers
102 views
For reasons that aren't important here, I need to be able to initiate the add/edit appointment process using the advanced edit form from a RadToolBar button rather than double-clicking on a timeslot or an existing appointment.

However, I can't find anything that obviously suggests itself as a way forward in the docs.

Is this something I can do entirely client-side? Or do I have to perform an AjaxRequest on the button click and call something server-side?

Hints, vague clues and fully-working examples complete with documentation and a free copy of half-life will all be appreciated. :-)

--
Stuart
Stuart Hemming
Top achievements
Rank 2
 answered on 06 Aug 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?