Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
148 views
If we place a .MOV file on a page (i.e. http://stage03.tsunami.aptinet.com/mov_test.aspx)
it does not play properly for users who do not have the QuickTime plug-in.  It simply shows a default QuickTime player that does not play anything

Here's the code

<object type="application/x-oleobject" height="150" width="150" classid="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95">
<param name="FileName" value="../UserControls/Handler.ashx?path=PLKNew/Objects/Media/sample_iTunes.mov"/>
<embed src="../UserControls/Handler.ashx?path=PLKNew/Objects/Media/sample_iTunes.mov" width="150" height="150" type="application/x-mplayer2" pluginspage="http://www.microsoft.com/Windows/MediaPlayer"></embed>
</object>

Question : IS it possible to change plugin from mediaplayer to quicktime for MOV files.

Thanks,
Shubod






Rumen
Telerik team
 answered on 10 Sep 2009
1 answer
184 views
Hi,

I've got a question regarding grid layout/css:

My client wants the command item bar on top to be a transparent one. Also he wants everything under it to have a border around it (so header, grouping, rows, footers edc) So, except for the command bar, the grid must have a border.

I've tried so, but thecommand bar and the column groups are in the same table, other tr's, the column headers are not in a seperated element, so i can set the left, top an right borders of the columns row.

Regards, Erik
Dimo
Telerik team
 answered on 10 Sep 2009
1 answer
210 views
Hi

I have the following that loads a Javascript function to run on page load:

        Dim MasterBody As HtmlGenericControl = Me.Master.body
        MasterBody.Attributes.Add("onload", "DoDetailsCalc()")

Depending upon the users preferences the javascript to run will either be DoDetailsCalc() as shown or DoTotalsCalc(). This is why I load it from code behind.

When I perform an update to the page, I want it to recalculate, this was working fine, until I put a RadAjaxManager on the page.

The page load is no longer firing in this situation.

How do I re run the javascript?

Andy
Sebastian
Telerik team
 answered on 10 Sep 2009
4 answers
158 views
Hi,

I am populating a Rad TreeView manually for the first level and then using a WCF Service when a user expands a node.
This was all working perfectly until today (1st Sept) when I started recieving the javascript error below.

The data contract type 'Telerik.Web.UI.RadTreeNodeData' cannot be deserialized
because the required data members '_attributes, _enabled, _text, _value,
_contentCssClass, _contextMenuID, _cssClass, _disabledCssClass, _disabledImageUrl,
_expandMode, _expandedImageUrl, _hoveredCssClass, _hoveredImageUrl, _imageUrl,
 _navigateUrl, _postBack, _selectedCssClass' were not found. 

Example post data:

{"node":{"Text":"XYZ","Value":null,"ExpandMode":3,"NavigateUrl":"/Child/XYZ75/","PostBack":true,"DisabledCssClass":null,"SelectedCssClass":null,
"HoveredCssClass":null,"HoveredImageUrl":null,"DisabledImageUrl":null,
"ExpandedImageUrl":null,"ContextMenuID":"BUCtxMenu",
"Attributes":[{"Key":"key","Value":"BU-370"},
{"Key":"A","Value":"False"},{"Key":"SIA","Value":"0"}]},"context":[]} 


Would anyone be able to suggest what might be causing this?

Thanks
Jonathan
Top achievements
Rank 1
 answered on 10 Sep 2009
7 answers
215 views
Hi there,

I have a Grid and I have templated the Footer. The problem is that the footer's content is starting half way. The effect is as if the footer is placing content in the second cell of a table.

<table>
    <tr><td>Can't get my content to align over here.<td>    <td> Content in the template starts here                   </td> </tr>
</table>

The above code is to sort of visual represent the problem I am having. I am not using tables in my template at all. I am just curious why the content isn't able to align left.

Any help would be greatly appreciated, thanks!

Jaime
Princy
Top achievements
Rank 2
 answered on 10 Sep 2009
2 answers
197 views
Hi,
I am using one rad grid 

 

 

<

telerik:RadGrid ID="RadGrid1" runat="server" AutoGenerateColumns="false" Skin="Office2007" AutoGenerateEditColumn="false" 

 

 

OnNeedDataSource="NeedData" AllowAutomaticInserts="True" AllowAutomaticUpdates="True" 

 

 

OnInsertCommand="Insert" OnUpdateCommand="Update"> 
<MasterTableView CommandItemDisplay="TopAndBottom"> 

 

 

<Columns> 

 

 

<telerik:GridTemplateColumn UniqueName="Attribute"> 

 

 

<ItemTemplate> 

 

 

<asp:Label ID="Label1" runat="server" Text='<%# Bind( "Attribute" ) %>'></asp:Label> 

 

 

</ItemTemplate>

 

 

</telerik:GridTemplateColumn> 

 

 

<telerik:GridTemplateColumn UniqueName="Val"> 

 

 

<ItemTemplate> 

 

 

<asp:Label ID="Label2" runat="server" Text='<%# Bind( "Val" ) %>'></asp:Label> 

 

 

</ItemTemplate>

 

 

</telerik:GridTemplateColumn> 

 

 

 

<telerik:GridEditCommandColumn HeaderText="Action"> 

 

 

</telerik:GridEditCommandColumn> 

 

 

</Columns> 

 

 

<EditFormSettings EditFormType="Template"> 

 

 

<FormTemplate> 

 

 

<asp:TextBox ID="txtAttribute" runat="server" Text='<%# Bind( "Attribute" ) %>'></asp:TextBox> 

 

 

<asp:TextBox ID="txtVal" runat="server" Text='<%# Bind( "Val" ) %>'></asp:TextBox> 

 

 

 

<asp:Button ID="btnUpdate" Text='<%# (Container is GridEditFormInsertItem) ? "Insert" : "Update" %>' 

 

 

runat="server" CommandName='<%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>'> 

 

 

</asp:Button>&nbsp; 

 

 

<asp:Button ID="btnCancel" Text="Cancel" runat="server" CausesValidation="False" 

 

 

CommandName="Cancel"></asp:Button> 

 

 

</FormTemplate> 

 

 

</EditFormSettings> 

 

 

</MasterTableView> 

 

 

</telerik:RadGrid>

 

 

 

Now how to hide the edit form after the Insert ? like the cancel

 

protected

void Insert(object source, GridCommandEventArgs e)

 

{

// some code



please help, it is very urgent.

arijit
Top achievements
Rank 1
 answered on 10 Sep 2009
3 answers
190 views
I currently have a listbox being populated from the client side. each time an ajaxfied timer ticks on the server side. I am wanting to always have the listbox scroll or stay scrolled at the bottom. The list box contains a list of messages from the server. and i am wanting the last message to always be visible which when i add it to listbox it is placed at the bottom.

any idea is appreciated
Veselin Vasilev
Telerik team
 answered on 10 Sep 2009
1 answer
176 views
I am trying to use the radupload control, and am having trouble connecting the "submit" button to the control.

After looking a the demos for this control, I can not see where the button is tied into the upload.

It would appear that the button click is simply toggling the visibility of labels and such.

How is the filexists fired? What controls it if I have multiple buttons in my page?

Obviously I am missing something here, any help would be greatly appreciated.

How does the code below trigger the file to be uploaded on the click of the button?


<telerik:RadUpload
                            ID="RadUpload1" runat="server"
                            MaxFileInputsCount="5"
                            TargetFolder="~/Upload/Examples/UsingTargetFolder/MyFiles"
                            OverwriteExistingFiles="false" />




<asp:Button id="buttonSubmit" runat="server" CssClass="RadUploadSubmit" OnClick="buttonSubmit_Click" text="Submit" />

 Protected Sub buttonSubmit_Click(ByVal sender As Object, ByVal e As System.EventArgs)
            If RadUpload1.UploadedFiles.Count > 0 Then
                repeaterResults.DataSource = RadUpload1.UploadedFiles
                repeaterResults.DataBind()
                labelNoResults.Visible = False
                repeaterResults.Visible = True
            Else
                labelNoResults.Visible = True
                repeaterResults.Visible = False
            End If
            DeleteFiles()
        End Sub


Protected Sub RadUpload1_FileExists(ByVal sender As Object, ByVal e As Telerik.Web.UI.Upload.UploadedFileEventArgs)
            Dim counter As Integer = 1
            Dim file As UploadedFile = e.UploadedFile
            Dim targetFolder As String = Server.MapPath(RadUpload1.TargetFolder)
            Dim targetFileName As String = Path.Combine(targetFolder, file.GetNameWithoutExtension() + counter.ToString() + file.GetExtension())
            While System.IO.File.Exists(targetFileName)
                System.Math.Max(System.Threading.Interlocked.Increment(counter),counter - 1)
                targetFileName = Path.Combine(targetFolder, file.GetNameWithoutExtension() + counter.ToString() + file.GetExtension())
            End While
            file.SaveAs(targetFileName)
        End Sub


Veselin Vasilev
Telerik team
 answered on 10 Sep 2009
2 answers
358 views

Hello;
I need to transfer items from one RadListBox to another RadListBox using client-side programming and both list boxes has item templates. I’ve noticed that the item is not moved correctly in that case unlike the case when the list box items do not have template.

 

Any help?

 

Here is the code snippet:

 

<table border="0" cellpadding="10" cellspacing="0">

        <tr>

            <td width="50%" align="center">

                <telerik:RadListBox runat="server" ID="rlb1" TransferMode="Move" SelectionMode="Single" AutoPostBack="true"

                    OnClientSelectedIndexChanged="selectedIndexChanged" Width="200px" Height="150px" DataTextField="Header" DataValueField="Header">

                    <ItemTemplate>

                        <asp:Image runat="server" ImageUrl="~/images/plus_009.gif" />&nbsp;<asp:Label runat="server" Text='<%# Eval("Header") %>' />

                    </ItemTemplate>

                </telerik:RadListBox>

            </td>

            <td align="center">

                <telerik:RadListBox runat="server" ID="rlb2" TransferMode="Move" SelectionMode="Single" Width="200px" Height="150px"

                    DataTextField="Header" DataValueField="Header">

                    <ItemTemplate>

                        <asp:Image runat="server" ImageUrl="~/images/plus_009.gif" />&nbsp;<asp:Label runat="server" Text='<%# Eval("Header") %>' />

                        &nbsp;<asp:Label runat="server" Text='<%# Eval("Desc") %>' />

                    </ItemTemplate>

                </telerik:RadListBox>

            </td>

        </tr>

    </table>

 

 

<telerik:RadScriptBlock runat="server">

<script language="javascript" type="text/javascript">

    function selectedIndexChanged(sender, args) {

        var listSource = $find("<%= rlb1.ClientID %>");

        var selectedItem = listSource.get_selectedItem();

 

        listSource.trackChanges();

 

        var listDest = $find("<%= rlb2.ClientID %>");

        //var item = new Telerik.Web.UI.RadListBoxItem();

        //item.set_text(selectedItem.get_text());

        //item.set_value(selectedItem.get_value());

        //var item = selectedItem.clone();

 

        listDest.trackChanges();

        listDest.get_items().add(selectedItem);

        //item.scrollIntoView();

        listDest.commitChanges();

 

        //listSource.get_items().remove(selectedItem);

        listSource.commitChanges();

    }

</script>

</telerik:RadScriptBlock>

 

 

 

Code behind (to fill the list box woth some data):

 

    protected void Page_Load(object sender, EventArgs e)

    {

        if (!Page.IsPostBack)

        {

            rlb1.DataSource = getTable();

            rlb1.DataTextField = "Header";

            rlb1.DataValueField = "Header";

            rlb1.DataBind();

        }

    }

    private DataTable getTable()

    {

        DataTable table = new DataTable();

        table.Columns.Add("Header", typeof(string));

        table.Columns.Add("Desc", typeof(string));

 

        DataRow row;

        #region Insert Data to Row

        row = table.NewRow();

        row["Header"] = "Head1";

        row["Desc"] = "Desc1";

        table.Rows.Add(row);

        #endregion

 

        #region Insert Data to Row

        row = table.NewRow();

        row["Header"] = "Head2";

        row["Desc"] = "Desc2";

        table.Rows.Add(row);

        #endregion

 

        #region Insert Data to Row

        row = table.NewRow();

        row["Header"] = "Head3";

        row["Desc"] = "Desc3";

        table.Rows.Add(row);

        #endregion

 

        #region Insert Data to Row

        row = table.NewRow();

        row["Header"] = "Head4";

        row["Desc"] = "Desc4";

        table.Rows.Add(row);

        #endregion

 

        return table;

    }

 

Genady Sergeev
Telerik team
 answered on 10 Sep 2009
8 answers
414 views
Hello,
I have just downloaded RadControls AJAX Q2 2008. Right after I start receive the error message 'XXXX' is ambiguous in the namespace 'Telerik.Web.UI'. This seems to be occuring on every page and every Rad Control.

Do I need t unstall Prometheus first???  or are there any other suggestions you can provide in correcting this error.

We are moving into Phase II of our project and the Rad controls have been a big hit so far.

Look forward to reading your reply.

 

Jay P. Hayes (MCTS SQL 2005)
Colonial Properties Trust (One CLP)
O – 205.795-8120
C – 205-789-1970

Sebastian
Telerik team
 answered on 10 Sep 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?