Telerik Forums
UI for ASP.NET AJAX Forum
0 answers
110 views
Hi,

I was trying to set AllowedFileExtensions in RadAsyncUpload, but no matter how I set it, it doesn't work (all the extensions are available) AND, what's worse, it breaks file size valildation - I have the MaxFileSize set for something like 3MB, but as long as AllowedFileExtensions are set, the validation fails for a 2MB file, while it lets through a file that is 18kB.

I've seen a few threads where you suggest to disable Silverlight. I've done it. I've also disabled flash - no avail.

I've tried to set it in markup, in code, using a dot before the extension as well as without it. Nothing works.

My project is using telerik 2010_3_something, so I thought maybe it got fixed in some newer version. I set up a new project with telerik 2012_1_529 in a totally new project - no change.

I'll probably try to use a custom validator now, hope it works... But anyway please tell me if there is possible to make it work anyway.
Chris
Top achievements
Rank 1
 asked on 10 Aug 2012
1 answer
109 views
Hi ,
 How do I change the border color of the selected date in radcalendar. Please help
Savyo
Princy
Top achievements
Rank 2
 answered on 10 Aug 2012
5 answers
162 views
I have a list in a RadDropDown, that users can select multiple values from, these are then saved to a database in a comma separated string.

When I wish to edit the data I need the same checkboxes to be ticked.

My code is atttached, I'm getting the first value to tick, but on subseqent values the x is null and no further binding takes place. The value of the selectedItem matched the value of Usr from the array.

'populate the dropdown and pre select checkboxes
If Not IsDBNull(u_ds.Tables(0).Rows(0)("LinkedUsers")) Then
    Dim arrLinkedUsers As Array = Split(u_ds.Tables(0).Rows(0)("LinkedUsers"), ",")
    For Each Usr In arrLinkedUsers
 
        ddlClinic.SelectedValue = Usr
        Dim x As RadComboBoxItem = DirectCast(ddlClinic.SelectedItem, RadComboBoxItem)
        If Not x Is Nothing Then
            x.Checked = True
        End If
 
    Next Usr
End If

Andy


Andy Green
Top achievements
Rank 2
 answered on 10 Aug 2012
1 answer
253 views
Hey Guys,

I've come up against a sticky one here.  I'm trying to apply a dynamic (from UserControl) ItemTemplate to my RadListView.
I do this OnItemDataBound and it works great except for the fact the ItemTemplate seems to have already been set up and so I end up modifying the template ready for the next record and not the current one.  So all templates are staggered out-of-sync by one record.
It seems there is no event to handle that lets me check my dataitem in time to set the current ItemTemplate.  I;ve read a solution online regarding the vanilla .NET ListView where you create a custom version which exposes what is effectively a "OnItemCreating" event where you can query the underlying data item in time to set the ItemTemplate accordingly.

I guess my question is really, have I missed something in Telerik's ListView that will allow me to do this?  And if not, can I extend the Telerik ListView in the manner of that example and create an event where I can carry out my desired operations?

Many thanks for any help - code snippets below.

<telerik:RadListView ID="rlvJobsListPage" runat="server" ItemPlaceholderID="phJobsList" DataSourceId="objJobList"
    OnItemDataBound="rlvJobsListPage_ItemDataBound" AllowCustomPaging="true" AllowPaging="true" PageSize="20" AllowSorting="True">
    <LayoutTemplate>
        <div id="searchList">
            <div id="phJobsList" runat="server"></div>
        </div>
    </LayoutTemplate>
    <EmptyDataTemplate>
        No records found
    </EmptyDataTemplate>
    <ItemTemplate>First item gets this default - not my dynamic template like the rest of them do</ItemTemplate>            
</telerik:RadListView>

protected void rlvJobsListPage_ItemDataBound(object sender, Telerik.Web.UI.RadListViewItemEventArgs e)
{
    // Set each bound item to status "Loaded"
    if (e.Item is RadListViewDataItem)
    {
 
        RadListViewDataItem thisDataItem = (RadListViewDataItem)e.Item;
        Job thisListing = (Job)thisDataItem.DataItem;
 
        //Formulate the Template name and Render it!
        rlvJobsListPage.ItemTemplate = Templating.Render_ITemplate(Globals.SectionIds.Jobs, thisListing.ListingTemplate, TemplateType.Summary, this);           
         
 
    }
}

Tsvetina
Telerik team
 answered on 10 Aug 2012
1 answer
95 views
I have a web user control.In my user control there is a asp:panel and in the asp:panel there are textboxes contexmenus and radgrids.
When I do enabled=false to panel only textboxes and contexmenus are be enabled=false. radgrids are still enabled=true
Why?
Eyup
Telerik team
 answered on 10 Aug 2012
3 answers
63 views
Hi,

I am trying to use the RadUpload control in my application, but I am getting some very strange results, and no matter what I do it doesn't seem to change it.
Please see the attached screen shot.
There are 2 edit controls swhowing per file, along with a Browse button AND a select button, as well as a dot to the left.
It is currently set to use the Office2010Blue skin, but seems to ignore this.
Markup for the upload control shown below


<div style="left: 0px; position:absolute; top: 60px; height: 230px; width: 320px;">
  <telerik:RadUpload ID="Upload" runat="server" MaxFileInputsCount="3" EnableEmbeddedSkins="true"
    ControlObjectsVisibility="RemoveButtons, AddButton" SkinID="Office2010Blue">
  </telerik:RadUpload>
</div>

Has anyone any idea how I can get this to look right?
What I really want, is for each file to show a text box, select button and remove button in the correct skin.


Thank you

Paul

Ivan Zhekov
Telerik team
 answered on 10 Aug 2012
4 answers
125 views
I have defined auto insert on my r.a.d. grid. When I click on Add New Record button, a form is displayed above the grid which displays all fields of the grid. This is default behavior of r.a.d grid. I want to achieve same behavior using code. Any idea?
Please help.
Radoslav
Telerik team
 answered on 10 Aug 2012
1 answer
113 views
Hello,

I am have currently added the following piece of JavaScript to the Column Resizing Event of a RadGrid I am using:

function ColumnResizing(sender, args)
{
    if (args.get_gridColumn()._columnResizer._currentWidth < 60)
    {
        args.set_cancel(true);
    }
}

It works so far, but now I would also like the "tool tip", which appears during the resizing and displays the exact width of the column, to stop at 60px. Is it possible to access the tool tip and set it's text in the code above, and would that work out as intended?

Thanks in advance,
Robin
Princy
Top achievements
Rank 2
 answered on 10 Aug 2012
2 answers
423 views
What I am trying to accomplish is writing a javascript function that when called from the click of a page element does the tabbing and changing of the of the RadTabStrip and RadMultiPage, with the option of passing a query string. However, I would like the option of passing in another boolean parameter that will notify the "sending" tab the next time it is clicked, it needs to reload its content. I have had some success in changing the RadTabStrip and RadMultiPage from my script, as well as the using the query string by changing the ContentUrl of the "target" PageView, but have been experiencing a lot of trouble in figuring out how to get the "sending" tab to reload its PageView.

Current JS file:
function ToolClick(sender, args, queryString, targetPageIndex, refreshSendingPage) {
    var revertContentUrl = false;
 
    // get the multi page ID, and tab strip ID, from the SiteAuthenticated script
    var multiPageID = top.GetMultiPageID();
    var multiPage = top.$find(multiPageID);
    var tabStripID = top.GetTabStripID();
    var tabStrip = top.$find(tabStripID);
 
    // get the target page view, and get its pre Tab Content URL for reverting after selection
    var multiPageViews = multiPage.get_pageViews();
    var targetPageView = multiPageViews._data[targetPageIndex];
    var preTabPageContentUrl = targetPageView.get_contentUrl();
 
    // change the page View's ContentUrl if the queryString was supplied
    if (queryString != null && queryString.length > 0) {
        targetPageView.set_contentUrl(preTabPageContentUrl + queryString);
        revertContentUrl = true;
    }
 
    // if refreshSendingPage is true then set the tab we are leaving to PostBack on next click
    if (refreshSendingPage) {
        var currentTab = tabStrip.get_selectedTab();
        currentTab.set_value("reload");
    }
 
    // do the tab change
    tabStrip.get_tabs()._array[targetPageIndex].select();   
 
    // if we changed the contentUrl for the query then change it back
    //if (revertContentUrl) {
    //    targetPageView.set_contentUrl(preTabPageContentUrl);
    //}
}
 
// to be used in determining if the tab needs to postBack or not
function TabStrip_OnTabSelecting(sender, args) {
    var selectingTab = args.get_tab();
    // check tab values for post back
    if (selectingTab.get_value() == "reload") {
        // the tab is set to post back so unload and reload the related pageView
    }
}


Thank you in advance for assistance.
Anton
Top achievements
Rank 1
 answered on 10 Aug 2012
1 answer
416 views

Hi,

  In Rad Panelbar we have an option to select the tempalte either  ItemTemplate or ContentTemplate. Which one is the best option to select as a Template. What is the difference in both these templates?.,   What are the difficulties occur when we are using these templates in ajax?


Thanks,
Velkumar.
Princy
Top achievements
Rank 2
 answered on 10 Aug 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?