Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
134 views
hi

I have a table with only one TemplateColumn.
but this column must show different figures by TYPE column of dataset. for example, if TYPE=1 then show user picture, Name and Family
and if TYPE=2 then show some other columns with a special figure.
that means i want make a table with Facebook wall stye that in every rows shows some data with true Template.
witch solution do you refer?

best regards
Mohammad

Princy
Top achievements
Rank 2
 answered on 25 Jul 2011
1 answer
124 views
This is strange. I have a radgrid with GridButtonColumn. The gridbuttoncolumn has a commandname of DeleteItem.

I pick this up on the server side in the Radgrid_Itemcommand sub. 

At this point I want to reference items in the grid to perform other functions. 

The code I have been using for an ID databound column (unique name mnu_3_id)

id =  radgrid1.Items.Item(e.Item.RowIndex)("mnu_3_id").Text

However, the rowindex that is returned is incorrect. It returns a number twice as big + 1. 

i.e. clicking row 0 results in a 2 being returned, row 1 a 4, row 2 a 6 etc.

I can obviously work around this, but why does it return the incorrect index?

Cheers

Tox
Shinu
Top achievements
Rank 2
 answered on 25 Jul 2011
2 answers
72 views
... now you don't.

I can't believe I am having this problem. I can make the rad window appear via a client side call to open it, but after postback the very same javascript will not open it.

I have created a small test project  to demonstrate the issue. I don't mind if this my own dumb fault, I just need to know why this is happening. :)

The form has a RadWindow inside a RadWindowManager and two buttons.

The first button is a regular html input type button that's 'onclick' calls the showWindow()  JS function.

The 2nd button is an asp:Button that on click postback to its own event handler. This method simply sets a value on the textbox that is in the window, then it registers some javascript that will call the ShowWindow function. It is on this 2nd call the ShowWindow fails to find the Window.

Here is the relevant part of the aspx code.

<head>
    <title>Now you see it...</title>
</head>
<body>
    <form id="form1" runat="server">
      
    <script type="text/javascript" language="javascript">
 
            function showWindow() {
                var win = $find("<%= RadWindow1.ClientID %>");
                alert(win); // Is NULL after post back
                win.show();
                win.center();
            }
 
    </script>  
 
    
   <asp:ScriptManager ID="ScriptManager1" runat="server">
   </asp:ScriptManager>
               
               <telerik:RadWindowManager ID="RadWindowManager1" runat="server">
                <Windows>
                    <telerik:RadWindow ID="RadWindow1" runat="server">
                        <ContentTemplate>
                            <asp:TextBox ID="tbTest" runat="server" />
                        </ContentTemplate>
                    </telerik:RadWindow>
                </Windows>
            </telerik:RadWindowManager>
    
    
           <input type="button" onclick="showWindow()" value="Client Side" />
                 
           <asp:Button ID="btnShowWindow"  runat="server" OnClick="btnShowWindow_Click" Text="Postback"/>
          
    </form>
</body>
</html>

The button event btnShowWindow_Click looks like this.

protected void btnShowWindow_Click(object sender, EventArgs e)
{
    tbTest.Text = "The window will not appear";
    string jScript = "showWindow();";
    ScriptManager.RegisterStartupScript(Page, Page.GetType(), "", jScript, true);
}

showWindow gets called just fine. However this time  does not work as the window is not found. (the Alert shows NULL)

This has to be simple. What am I missing here?


Brad
Top achievements
Rank 1
 answered on 25 Jul 2011
1 answer
1.5K+ views
How to remove the Alternative Row color in RadGrid?.

I have used the following two properties

ItemStyle-BackColor

 

="White" AlternatingItemStyle-BackColor="White"

 


When I use the above property the grid visibility having some patches. The attached image having the sample.

Princy
Top achievements
Rank 2
 answered on 25 Jul 2011
0 answers
78 views
Hi,
 I am new for this product. I have sharepoint 2007 and vs 2008. i would like to use RADGRID to display multiple sharepoint list with add and edit feature and also want to use master child feature. i would like to make custom web part only in C#. So can you please help me to create this web part.  I am looking for any example in C# so i can start.


Thank You So much in advance !!!
Dipesh
Top achievements
Rank 1
 asked on 25 Jul 2011
23 answers
391 views
I am using RADcontrols for ASP.NET version 2008.2.804.20

The documentation at http://www.telerik.com/help/aspnet-ajax/onpopupshowing.html has the following example:

ascx/aspx

<ClientEvents OnPopUpShowing ="PopUpShowing" />

JavaScript

   <script type="text/javascript">
        function PopUpShowing(sender, eventArgs)
        {
                var  popUp = eventArgs.get_popUp();
        }

        or

        function PopUpShowing(sender, eventArgs)
        {
               eventArgs.set_cancel(true);
        }

  </script>

Which by the way does not work for my version of the controls.

I figured out I need to change

 <ClientEvents OnPopUpShowing ="PopUpShowing" />
  to
<ClientSettings  ClientEvents-OnPopUpShowing="PopUpShowing()" >

My javascript function that is called when the popup shows is

     function PopUpShowing(sender, eventArgs) {
         $('.GridEditForm_Custom').height($('#AnswerOptionsGrid').height() + 230);
     }

which uses jQuery to change the height of the grid edit form based on the height of a sub grid on the form.

The height does get adjusted, however a "sys.InvalidOperationException: handler must be a function" error is also thrown.

If I replace the $('.GridEditForm_Custom').height($('#AnswerOptionsGrid').height() + 230);
with a simple alert('test'); the same error is produced.

Any help will be appreciated,

Keith E.


cory
Top achievements
Rank 1
 answered on 25 Jul 2011
5 answers
142 views
Hi,

this is my scenario

i use radrotator to make an image gallery like this one on your demo
http://demos.telerik.com/aspnet-ajax/rotator/examples/gallery/defaultcs.aspx

in the thumbnail in the bottom, i add radtooltips for some action like delete the photo

when i pass over the photo, the tooltip show and if i click on the linkbutton (delete this photo) i want to show a radconfirm dialog (do you realy want to delete this photo ?)

if yes then i delete the photo.

all of this is working good but the rotator not refresh. i try databind and its not working

i put un refresh button in that page but not ajaxified, the only thing this button do is in the code behin, rotator.databind.

how can i refresh the rotator like the refresh button ?

thanks !

Eric
Sergei
Top achievements
Rank 1
 answered on 25 Jul 2011
3 answers
122 views
Hi,

I'm relatively new to RadControls, and have a couple of questions about using DetailTables inside RadGrid.

1. My detail GridTableView has a delete button that uses the Delete Command, and that works fine, but I want another detail grid on the page to be updated (via ajax) when that happens. I added the master RadGrid as a control to initiate an update, and the other grid as the AjaxUpdatedControl, but deleting a detail record does not seem to cause an update in the other detail table. Do I need to do something else to achieve this?

1a. I acheved the result I want using a nested RadGrid in an edit form on the master, and trapping the OnItemDeleted event, but that seems like the long way round, and the UI is more cumbersome, I'd really rather use the DetailTables if I can.

Thanks for any help,

ROSCO
Lucania
Top achievements
Rank 1
 answered on 25 Jul 2011
11 answers
366 views
Is it possible to enable horizontal scrolling of the RadScheduler in TimelineView. For example, I would like to setup the TimelineView with 24 slots each with a 1 hour duration and then be able to set the width property on the RadScheduler such that the first 10 hours appear and the user would need to scroll to see the remaining 14 hours in the day.

I tried to put the RadScheduler inside of a parent div with a specified width (900px) and set the width of the RadScheduler wider (1400px) , but the Timeline table was not contained within the parent div. Is it possible to do this?

Thanks.
Peter
Telerik team
 answered on 24 Jul 2011
3 answers
167 views
Is there anything in the works to add an Agenda View to the Scheduler control?  My definition of an Agenda View is essentially a datagrid of entries by date & time.  It would be very similar to the calendar display that is available in Outlook when you go to your Outlook Today view.

In addition to an actual agenda view, is there anyway to display the scheduler data in a relational format (i.e. the ability to see the top level appointments and when an entry is recurring, a plus sign shows up that the user could click to display all the recurring entries below it.)?

Thanks,
Josh

Peter
Telerik team
 answered on 24 Jul 2011
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?