Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
184 views
Hello,

I have a dynamicly created RadGrid with GridButtonColumns.  I am using RadGrid1_ItemCommand event to identify which button was pressed.

How can I call a Javascript function in my header at this point? 

I have tried RowClick which does not fire on GridButtonColumns.

Thanks in advance.

David
Shinu
Top achievements
Rank 2
 answered on 20 Aug 2008
1 answer
151 views
Is there any way to make the entire RadChart Clickable? I know you can set certain parts of the chart to have active regions however is there a way to do this for the entire chart object?
Giuseppe
Telerik team
 answered on 20 Aug 2008
1 answer
112 views

Hi all,

We have a Radgrid in a web page on Server A that is used inside a web app in an iframe on server B.  Basically this means it’s in a different domain and access to parent objects is not allowed.
 

When the mouse moves over the grid a javascript error “Access is denied” appears because of “top.document”.  Full details are: 

ScriptResource.axd - line 5959 

var offsetL = w.screenLeft - top.screenLeft - top.document.documentElement.scrollLeft + 2; 

Is there some way that we can configure the control to not have this issue?  Can we have exception handling placed into the javascript? 

ASPX Layout is defined below

 <telerik:RadGrid ID="rgLog" runat="server" AutoGenerateColumns="False" GridLines="None"    OnItemDataBound="rgLog_ItemDataBound" OnNeedDataSource="rgLog_NeedDataSource" Width="100%" OnDetailTableDataBind="rgLog_DetailTableDataBind" Skin="Outlook" ShowHeader="False">
    <MasterTableView>
        <RowIndicatorColumn>
            <HeaderStyle Width="20px" />
        </RowIndicatorColumn>
        <ExpandCollapseColumn>
            <HeaderStyle Width="20px" />
        </ExpandCollapseColumn>
    </MasterTableView>
</telerik:RadGrid>

Thanks in advance!

Konstantin Petkov
Telerik team
 answered on 20 Aug 2008
1 answer
127 views
I am having a problem with the OnRowClick event.  Here is the code.

<

script type="text/javascript">

var

Grid

function

RowSelected(rowIndex)

{

alert(

"Click on row with index: " + rowIndex);

var path = Grid.getCellByColumnUniqueName(Grid.Rows[rowIndex], "DT_FilePath").innerHTML;

var Filename = Grid.getCellByColumnUniqueName(Grid.Rows[rowIndex], "DT_FileName").innerHTML;

alert(

"Path=" + path);

alert(

"Filename=" + Filename);

}

function

GridCreated() {

alert(

"Grid with ClientID: " + this.ClientID + " was created");

Grid =

this;

}

 

</

script>

<

rad:RadGrid ID="DocGrid" runat="server" AutoGenerateColumns="False" DataSourceID="SDS1" GridLines="None" Skin="Green" EnableAJAX="True">

<ClientSettings ApplyStylesOnClient="True">

<Selecting AllowRowSelect="True"></Selecting>

<ClientEvents OnRowClick="RowSelected" OnGridCreated="GridCreated">

</ClientEvents>

</ClientSettings>

<

MasterTableView DataSourceID="SDS1" GridLines="Both">

<

RowIndicatorColumn>

<

HeaderStyle Width="20px"></HeaderStyle>

</

RowIndicatorColumn>

<

ExpandCollapseColumn>

<

HeaderStyle Width="20px"></HeaderStyle>

</

ExpandCollapseColumn>

<Columns>

<rad:GridBoundColumn DataField="DT_FileNum" HeaderText="DT_FileNum" SortExpression="DT_FileNum" UniqueName="DT_FileNum" Display="False">

</rad:GridBoundColumn>

<rad:GridBoundColumn DataField="DT_Desc" HeaderText="Document" SortExpression="DT_Desc" UniqueName="DT_Desc">

<ItemStyle Font-Size="Small" />

</rad:GridBoundColumn>

<rad:GridBoundColumn DataField="DT_DateTime" DataType="System.DateTime" HeaderText="Create Date" SortExpression="DT_DateTime" UniqueName="DT_DateTime"

DataFormatString="{0:MM/dd/yyyy}">

<HeaderStyle Width="70px" />

<ItemStyle Font-Size="Small" />

</rad:GridBoundColumn>

<rad:GridBoundColumn DataField="DT_Clerk" HeaderText="Clerk" SortExpression="DT_Clerk" UniqueName="DT_Clerk">

<HeaderStyle Width="80px" />

<ItemStyle Font-Size="Small" />

</rad:GridBoundColumn>

<rad:GridBoundColumn DataField="DT_FilePath" Display="False" HeaderText="DT_FilePath" SortExpression="DT_FilePath" UniqueName="DT_FilePath">

</rad:GridBoundColumn>

<rad:GridBoundColumn DataField="DT_FileName" Display="False" HeaderText="DT_FileName" SortExpression="DT_FileName" UniqueName="DT_FileName">

</rad:GridBoundColumn>

<rad:GridBoundColumn DataField="DT_DocumentCategory" HeaderText="Category" SortExpression="DT_DocumentCategory" UniqueName="DT_DocumentCategory">

<ItemStyle Font-Size="Small" />

</rad:GridBoundColumn>

</Columns>

</

MasterTableView>

</

rad:RadGrid>

<

asp:SqlDataSource ID="SDS1" runat="server" ConnectionString="<%$ ConnectionStrings:CASConnection %>"

SelectCommand="SELECT [DT_FileNum], [DT_Desc], [DT_DateTime], [DT_Clerk], [DT_FilePath], [DT_FileName], [DT_DocumentCategory] FROM [DocumentTable] WHERE ([DT_FileNum] = @DT_FileNum) ORDER BY [DT_DateTime] DESC, [DT_Desc]">

<SelectParameters>

<asp:SessionParameter DefaultValue="1999001544" Name="DT_FileNum" SessionField="FileNum" Type="String" />

</SelectParameters>

</

asp:SqlDataSource>

In the RowSelected function I get the first alert but not the last two.  What am I doing wrong.

Thanks.

Konstantin Petkov
Telerik team
 answered on 20 Aug 2008
3 answers
200 views

I have a datetime column in which i have dbnull values in several rows.  When I try and filter the column, I get the following:

Specified cast is not valid.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.InvalidCastException: Specified cast is not valid.

It appears that the filter doesn't handle nulls.

Any ideas?

Thanks,

Terry Webster

Konstantin Petkov
Telerik team
 answered on 20 Aug 2008
1 answer
157 views

I have a problem with onclick property when I run my project. After run the project I try to click combobox and then I get an error like this:
Microsoft JScript runtime error: Object expected
I get an error on this row:

<fieldset style="width: 170px;" id="Fieldset3" onclick="return FIELDSET3_onclick()">

I get the same error on onclick property of  radwindowmanager

<telerik:RadWindowManager

id="Odeyen_window"

runat="server" Skin ="Web20"

OnClientPageLoad="CenterAc()" > //I got error on this row

<windows>

<telerik:RadWindow id="PrintWnd"

Modal = "True"

Runat="server"

Skin ="Web20"

NavigateUrl="" Title="">

</telerik:RadWindow>

</windows>

</telerik:RadWindowManager>

And here is my CenterAc function

function GetRadWindow()

{

var oWindow = null;

if (window.radWindow) oWindow = window.radWindow;

else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;

return oWindow;

}

function

CenterAc()

{

GetRadWindow().Center();

}

please help me to solve this problem

thanks

 

Georgi Tunev
Telerik team
 answered on 20 Aug 2008
1 answer
167 views
I've got a client wondering about obfuscating emails and I rememberd this old thread:

http://www.telerik.com/community/forums/thread/b311D-ecceg.aspx

Has anybody ever come up with a way to do this yet?
Rumen
Telerik team
 answered on 20 Aug 2008
4 answers
202 views
This is purely my lack of understanding, but I everything I have read so far has not really clicked yet, so I thought I would just come out and ask.  As a simplified example I have a master page with a RadAjaxManager control and two ContentPlaceHolder area declared.  I have a content page that defines content for the two ContentPlaceHolders like so.

<asp:Content ID="Content4" ContentPlaceHolderID="ContentPlaceHolderMain" Runat="Server"
    <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server"
    </telerik:RadAjaxManagerProxy> 
    <asp:Button ID="Button1" runat="server" Text="Button" onclick="Button1_Click" /> 
</asp:Content> 
 
<asp:Content ID="content5" ContentPlaceHolderID="ContentPlaceHolderRight" runat="server"
    <asp:TextBox ID="TextBox1" runat="server" Text="0"></asp:TextBox>     
</asp:Content> 

and a very simple iterate algorithm on click

 protected void Page_Load(object sender, EventArgs e) 
    { 
        this.RadAjaxManagerProxy1.AjaxSettings.AddAjaxSetting(Button1, TextBox1, null); 
    } 
 
    protected void Button1_Click(object sender, EventArgs e) 
    { 
        this.TextBox1.Text = (int.Parse(this.TextBox1.Text) + 1).ToString(); 
    } 


If I comment out the Page_Load contents.  the iterator works as expected with full page post backs.  However, with the AddAjaxSetting() method being called I always receive the exception Object reference not set to an instance of an object. on that line.  Button1 has a non null value, TextBox1 has a non null value, and RadAjaxManagerProxy1 has a non null value.  What is the piece I am missing here? 

Thanks for your time.


Konstantin Petkov
Telerik team
 answered on 20 Aug 2008
1 answer
198 views
I have a radMenu object in my master page.

<rad:RadMenu id="reACTMenu" runat="server" Skin="Web20" Width="922px" EnableEmbeddedSkins="false"></rad:RadMenu> 

 

When I open a modal dialog box in a page using this master page, the menu bar appears above the window.

Here is the window definition:

  <rad:RadWindowManager id="WindowMgr"   
        runat="server"   
        Skin="Vista" 
        VisibleStatusbar="false" 
        OnClientClose="OnWindowClose">  
        <windows> 
            <rad:RadWindow id="RelateWindow" 
               Modal="true" 
               Runat="server" 
               Width="400px" 
               Behavior="Move,Close" 
               Height="400px" 
               NavigateUrl="AppendTicketSearch.aspx" 
               OnClientShow="centerWindow" 
               OnClientClose="afterRelate">  
            </rad:RadWindow> 
Georgi Tunev
Telerik team
 answered on 20 Aug 2008
6 answers
323 views
I have been searching for help on creating a custom dropdown/split button in RadEditor for asp.net ajax, to behave similarly to the undo/redo buttons or the insert table button for example.

Is this possible? If so, how would I get started?

Thanks,

Rowen
Rowen
Top achievements
Rank 1
 answered on 19 Aug 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?