Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
42 views
Hi I have a webpart in sharepoint 2007 that load a web usercontrol. this Web Usercontrol has RadAjaxmanager with the client-event OnRequestStart. when the user clicks the RadTabSplit the first time the OnrequestStart is trigged but in the second time does not trigged again.  Actually the RadAjaxLodingPanel is not work neither. I test the same code outside Sharepoint in a web application solution and it is working correctly. What is the problem? should I do something diferent in sharepoint 2007? 

I am working wih this problem for three days and I have read many blog and forums but nobody has the answer. Please help me!!
HANK 

Maria Ilieva
Telerik team
 answered on 26 Apr 2011
3 answers
165 views
Hi

I'm currently developing Tablet based Web Application using Telerik Controls.  I'm trying to prevent users from clicking/touching the cancel button when trying Inserting an item into the Grid. Is there a way to move the Cancel Image Button to the right hand side of the items when in Insert Mode?

I'm assuming I could build custom Cancel/Insert Buttons using RadButtonColumns on either side, but was hoping that there's maybe a simpler/cleaner way of achieving this.

Best Regards,

Landon
Mira
Telerik team
 answered on 26 Apr 2011
8 answers
173 views
I am using the RadMenu downloaded version Q1 2011 and cannot get the menu to load. The page errors out with the following error:

Parser Error Message: Could not load file or assembly 'Telerik.Web.UI, Version=2011.1.315.1040, Culture=neutral, PublicKeyToken=121fae78165ba3d4' or one of its dependencies. The system cannot find the file specified.

I used the following website to assist me setting up the RadMenu http://www.sharemuch.com/2011/01/20/branding-sharepoint-2010-integrating-telerik-controls-in-sharepoint-site/

I modified the Telerik control to Version to the current build number as listed on this URL http://www.telerik.com/community/code-library/silverlight/general/submit-example.aspx

On the error page it states I am using Version Information: Microsoft .NET Framework Version:2.0.50727.5420; ASP.NET Version:2.0.50727.5420 However, when checking the Server Manager I have installed the Role Service of .Net Framework 3.5.1

Could this be the problem? Do I need to upgrade my .Net Framework Version to more recent copy?

As stated in this post http://www.telerik.com/community/forums/aspnet-ajax/editor/config-telerik-web-ui-dll-version-2010-1-415-35-in-sharepoint-2010.aspx I followed the instructions and placed code into the web.config for <SafeControl> and the <handlers> tags as directed.

What am I doing wrong?

I see in the threaded discussion that I may be using the wrong build:

----------
Posted on Jun 30, 2010 (permalink)

Hi Akhilaa,

I can see that you incorporated ASP.NET AJAX 3.5 in your MOSS site and you are trying to use the 2010.1.415.20 version of Telerik.Web.UI, which is built against .NET 2.0 framework. What you need to do is either use the 2010.1.415.35 version of Telerik.Web.UI, which is built against .NET 3.5 framework
---------

Is changing the build version the only issue? Are there any other roadblocks I should expect to find?

Please help!!!

Thank you.
Kalina
Telerik team
 answered on 26 Apr 2011
1 answer
77 views
We are creating a dynamic menu using a Mega Nav, a multi-column display and static menus. One of the columns holds a drop-down menu which we want to display the LISTS and LIBRARIES for the current SharePoint 2010 site. We want to have no other menu items displayed in this particular drop-down. Can someone help us how to get the results we are looking for? We have been attempting to use the SITEMAPDATASOURCE, however, this returns the entire site map structure which is way too much information. Based on which site a user is at this drop-down menu will only display the lists and libraries for that site only. It would dynamically look at the parent and children in the hierarchy and display the current location. While we believe this is the correct path we don't know the proper steps to code it correctly.

Regards,
Alex Dove
Kalina
Telerik team
 answered on 26 Apr 2011
3 answers
168 views
We are creating a dynamically created menu based off the DataSourceID="SiteMapDataSource" property. While this gives us the functionality we wanted it also displays LISTS, LIBRARIES and DISCUSSIONS on the top-level navigation. We only want to have top-level sites on the home page and sibling sub-sites displayed on the landing page of sub-sites. We have removed the Quick Launch to gain valuable real estate and therefore need to display the LISTS, LIBRARIES and DISCUSSIONS underneath a site menu item as a drop-down item. How do we accomplish this? I have attached a screenshot of our current site menu which displays ALL of the sitemap content in the top-level navigation. How do we move the LISTS, LIBRARIES and DISCUSSIONS into a separate drop-down? I have also attached 2 more images called "telerik_menu_dropdown.gif" which displays the menu items we need removed from the root menu and then image attachment named "telerik_menu_subsite_sample.gif" which is a child site of the parent. This top-level navigation is displayed correctly with all of the menu items listed vertically inside a drop-down menu.

Thanks
Alex
Kalina
Telerik team
 answered on 26 Apr 2011
3 answers
81 views
Hi all,

My snip code as below : 
public class Marble : ISkin
    {
        public Marble()
        {
        }
 
        public string GetCSS()
        {
            StringBuilder css = new StringBuilder();
            css.Append(@"
<Chart SkinName=""Marble"">
  <ChartTitle>
    <Appearance>
      <FillStyle MainColor=""Transparent"" />
      <Position AlignedPosition=""Top"" />
    </Appearance>
    <TextBlock>
      <Appearance>
        <TextProperties Font=""Arial, 22pt"" Color=""89, 79, 52"" />
      </Appearance>
    </TextBlock>
  </ChartTitle>
  <Legend>
    <Appearance Overflow=""Row"">
      <ItemTextAppearance>
        <TextProperties Color=""101, 91, 72"" Font=""Georgia, 9pt"" />
      </ItemTextAppearance>
      <FillStyle MainColor=""Transparent"" />
      <Position AlignedPosition=""Bottom"" />
      <Dimensions Margins=""17.6%, 3%, 1px, 1px"" />
      <Border Color=""Transparent"" />
    </Appearance>
  </Legend>
  <Appearance TextQuality=""AntiAlias"">
    <FillStyle FillType=""Image"">
      <FillSettings ImageDrawMode=""Flip"" BackgroundImage=""{chart}"" />
    </FillStyle>
    <Border Color=""181, 166, 132"" />
  </Appearance>
  <PlotArea>
    <XAxis>
      <Appearance Color=""Transparent"">
        <MajorGridLines PenStyle=""Solid"" Color=""94, 93, 87"" />
        <MajorTick Color=""173, 164, 142"" />
        <TextAppearance>
          <TextProperties Color=""101, 91, 72"" Font=""Georgia, 9pt"" />
        </TextAppearance>
      </Appearance>
      <AxisLabel>
        <TextBlock>
          <Appearance>
            <TextProperties Color=""101, 91, 72"" Font=""Georgia, 9pt"" />
          </Appearance>
        </TextBlock>
      </AxisLabel>
    </XAxis>
    <YAxis>
      <Appearance Color=""Transparent"">
        <MajorGridLines PenStyle=""Solid"" Color=""94, 93, 87"" />
        <MinorGridLines PenStyle=""Solid"" Color=""94, 93, 87"" />
        <MinorTick Color=""173, 164, 142"" />
        <MajorTick Color=""173, 164, 142"" />
        <TextAppearance>
          <TextProperties Color=""101, 91, 72"" Font=""Georgia, 9pt"" />
        </TextAppearance>
      </Appearance>
      <AxisLabel>
        <TextBlock>
          <Appearance>
            <TextProperties Color=""101, 91, 72"" Font=""Georgia, 9pt"" />
          </Appearance>
        </TextBlock>
      </AxisLabel>
    </YAxis>
    <Appearance>
      <FillStyle FillType=""Image"">
        <FillSettings ImageDrawMode=""Flip"" BackgroundImage=""{plotarea}"" ImageAlign=""Top"" ImageFlip=""FlipY"" />
      </FillStyle>
      <Dimensions Margins=""22%, 24%, 12%, 10%"" />
      <Border Color=""144, 136, 118"" Width=""8"" />
    </Appearance>
  </PlotArea>
</Chart>");
            return css.ToString();
        }
    }

In the marble skin, we see two params {image}  and {plotarea}. If we do not custom css, chart can show the background. However, I want to custom some its style, its background cannot show.

Please help.

Thanks / Phong Dang.
Vladimir Milev
Telerik team
 answered on 26 Apr 2011
8 answers
160 views
We have a very strange problem, we have a RadGrid that is invisible inside an UpdatePanel, that is set as the receiver of AJAX requests (along with other control). When the sender initiates an AJAX request, the RadGrid will try to DataBind, even though it is still invisible, which seem strange. Is this really expected behaviour or is it a bug? In my world, and invisible RadGrid should never try to DataBind by itself (all data operations for the grid is handled automatically).
Martin
Telerik team
 answered on 26 Apr 2011
1 answer
81 views
hi

This is my code:

<ResourceTypes>
                     <telerik:ResourceType DataSourceID="sdsUsers" ForeignKeyField="UserID"
                         KeyField="UserID" Name="User_Name" TextField="User_Name" />
</ResourceTypes>

    Protected Sub RadScheduler1_AppointmentDataBound(ByVal sender As Object, ByVal e As Telerik.Web.UI.SchedulerEventArgs) Handles RadScheduler1.AppointmentDataBound
        If e.Appointment.Resources.GetResourceByType("User_Name") IsNot Nothing Then
            e.Appointment.BackColor = DataBinder.Eval(e.Appointment.Resources.GetResourceByType("User_Name").DataItem, "BackColor")
        End If
    End Sub

My user table schema:

UserID
User_Name
BackColor

I still do not get any color for the scheduler. What went wrong with my setting?

Veronica
Telerik team
 answered on 26 Apr 2011
1 answer
81 views
How can I make the cover flow items clickable? The demo doesn't do this.

Thanks!
Niko
Telerik team
 answered on 26 Apr 2011
8 answers
923 views
Hi,

I am working on a scenario where Feeds are downloaded from a web URL. Since this feed downloading can be a time taking process, I want to shift this logic and grid databinding to Async mode.
I did checked different threads talking about NeedDatasource to other approaches but none of them is working for me. Given below is code for your reference:

//WebUserControl1.ascx

<%

 

@ Control Language="C#" AutoEventWireup="true" CodeFile="WebUserControl1.ascx.cs" Inherits="WebUserControl1" %>

 

 

<%

 

@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>

 

 

 

<

 

 

telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">

 

<

 

 

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

 

 

 

function OnRowClicked(sender, eventArgs) {

 

 

 

 

var newsDetailURL = eventArgs.getDataKeyValue("link") + '&style=html';

 

 

 

 

var index = newsDetailURL.indexOf('http://');

 

 

 

 

if (index == -1) {

 

 

newsDetailURL = newsDetailURL.replace(

 

'http:/', 'http://');

 

 

}

 

window.open(newsDetailURL,

 

'', 'location=0,status=0,toolbar=0,directories=no,menubar=no,titlebar=no,scrollbars=1,resizable=1');

 

 

}

 

 

 

function RebindNewsFeeds() {

 

 

 

 

var btnRebind = $get('<%= btnReload.ClientID %>');

 

 

btnRebind.click();

 

}

 

 

 

function ResizeNewsFeed() {

 

 

 

 

// var grid = document.getElementById("<%= RadGridNewsFeed.ClientID %>"); //$find("< % = .ClientID % >");

 

 

 

// var parentDiv = grid.parentNode;

 

 

 

// var documentObj = document.documentElement;

 

 

 

// if (window.opera || (document.all && !(document.compatMode && document.compatMode == "CSS1Compat"))) {

 

 

 

// documentObj = document.body;

 

 

 

// }

 

 

 

// parentDiv.height = '100%';

 

 

 

// parentDiv.width = '100%';

 

 

 

// parentDiv.style.height = '100%';

 

 

 

// parentDiv.style.width = '100%';

 

 

 

try {

 

 

 

 

var grid = $find("<%= RadGridNewsFeed.ClientID %>");

 

 

grid._scrolling._initializeDimensions();

 

 

 

//grid.repaint();

 

}

 

catch (ex) { }

 

 

}

</

 

 

script>

 

 

</

 

 

telerik:RadCodeBlock>

 

 

<

 

 

telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Skin="Default">

 

 

 

</telerik:RadAjaxLoadingPanel>

 

 

<

 

 

telerik:RadAjaxPanel ID="RadAjaxPanel1" LoadingPanelID="RadAjaxLoadingPanel1" runat="server" Height="100%" Width="100%">

 

 

 

 

<telerik:RadGrid ID="RadGridNewsFeed" runat="server"

 

 

 

 

AutoGenerateColumns="False" OnItemDataBound="RadGridNewsFeed_ItemDataBound"

 

 

 

Skin="Grid" EnableEmbeddedSkins="False" GridLines="None"

 

 

 

 

HeaderStyle-Width="100%" ItemStyle-Width="100%" width="100%"

 

 

 

 

Height="100%" AllowSorting="True" ItemStyle-Wrap="false"

 

 

 

style="margin:0; border: 0; outline: none"

 

 

 

 

EnableViewState="False" onneeddatasource="RadGridNewsFeed_NeedDataSource" >

 

 

 

 

<MasterTableView Width="100%" CellPadding="0" CellSpacing="0"

 

 

 

 

ClientDataKeyNames="link" ShowHeadersWhenNoRecords="true"

 

 

 

 

AllowNaturalSort="false" TableLayout="Auto" EnableViewState="False">

 

 

 

 

<SortExpressions>

 

 

 

<telerik:GridSortExpression FieldName="pubDate" SortOrder="Descending" />

 

 

 

</SortExpressions>

 

 

 

 

<CommandItemSettings ExportToPdfText="Export to Pdf" />

 

 

 

<RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">

 

 

 

</RowIndicatorColumn>

 

 

 

<ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">

 

 

 

</ExpandCollapseColumn>

 

 

 

<Columns>

 

 

 

<telerik:GridBoundColumn DataField="pubDate" HeaderText="Date" UniqueName="pubDate">

 

 

 

<HeaderStyle HorizontalAlign="Left" Width="20%" />

 

 

 

</telerik:GridBoundColumn>

 

 

 

<telerik:GridBoundColumn DataField="Title" HeaderText="Title" UniqueName="Title" HeaderStyle-Width="80%">

 

 

 

<HeaderStyle HorizontalAlign="Left"/>

 

 

 

<ItemStyle Wrap="false" />

 

 

 

</telerik:GridBoundColumn>

 

 

 

<telerik:GridBoundColumn DataField="link" HeaderText="Detail News Link" UniqueName="link" Visible="false">

 

 

 

<HeaderStyle HorizontalAlign="Left" />

 

 

 

 

</telerik:GridBoundColumn>

 

 

 

</Columns>

 

 

 

 

<EditFormSettings>

 

 

 

<EditColumn CancelImageUrl="Cancel.gif" EditImageUrl="Edit.gif"

 

 

 

 

FilterControlAltText="Filter EditCommandColumn column"

 

 

 

 

InsertImageUrl="Update.gif" UpdateImageUrl="Update.gif">

 

 

 

</EditColumn>

 

 

 

</EditFormSettings>

 

 

 

</MasterTableView>

 

 

 

 

<SortingSettings EnableSkinSortStyles="false" />

 

 

 

 

<ClientSettings EnableRowHoverStyle="true" >

 

 

 

<ClientEvents OnRowClick="OnRowClicked" />

 

 

<%

 

--<Scrolling AllowScroll="true" UseStaticHeaders="true" SaveScrollPosition="true" ScrollHeight="100%"/>--%>

 

 

 

 

</ClientSettings>

 

 

 

 

<HeaderStyle Width="100%" />

 

 

 

<ItemStyle Width="100%" Wrap="False" />

 

 

 

<FilterMenu EnableEmbeddedSkins="False" EnableImageSprites="False">

 

 

 

</FilterMenu>

 

 

 

<HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Grid"

 

 

 

 

EnableEmbeddedSkins="False">

 

 

 

</HeaderContextMenu>

 

 

 

</telerik:RadGrid>

 

 

<

 

 

asp:Button ID="btnReload" SkinID="ButtonHidden" runat="server" OnClick="btnReload_Click"

 

 

 

Text="Button" />

 

 

 

 

<input type="hidden" id="txtLastUrl" runat="server" value ="" />

 

</

 

 

telerik:RadAjaxPanel>

 

 

//Code WebUserControl1.ascx.cs

using

 

 

System;

 

using

 

 

System.Collections.Generic;

 

using

 

 

System.Linq;

 

using

 

 

System.Web;

 

using

 

 

System.Web.UI;

 

using

 

 

System.Web.UI.WebControls;

 

using

 

 

Telerik.Web.UI;

 

using

 

 

System.Data;

 

using

 

 

System.Net;

 

public

 

 

partial class WebUserControl1 : System.Web.UI.UserControl

 

{

 

 

DataSet _dsNewsFeed = null;

 

 

 

 

const string styleTag = "&style=html";

 

 

 

 

private delegate void DownloadNewsFeedData(string val);

 

#region

 

 

Cotrol Events

 

 

 

 

/// <summary>

 

 

 

/// It will be called whenver master form is laoded or refreshed

 

 

 

/// </summary>

 

 

 

/// <param name="sender">Caller of the event</param>

 

 

 

/// <param name="e">Event info which is passed along the method</param>

 

 

 

protected void Page_Load(object sender, EventArgs e)

 

 

{

 

 

 

if (!IsPostBack)

 

 

LoadNewsFeed();

 

}

#endregion

#region

 

 

Public Routines

 

 

 

 

/// <summary>

 

 

 

/// It will be called whenever you want to hit the third party server to download the feed for the active company

 

 

 

/// </summary>

 

 

 

public void LoadNewsFeed()

 

 

{

 

 

 

try

 

{

 

 

 

//Formulate the url to get the news for the company

 

 

 

string newsFeedURL = "http://savanet.acquiremedia.com/news/search";

 

 

 

 

string companyNewsFeedURL = "http://savanet.acquiremedia.com/news/search?query=/ANN";

 

 

_dsNewsFeed =

 

new DataSet();

 

 

 

 

//GetNewsFeedDataTable(companyNewsFeedURL);

 

 

 

////Call async thread to download news feed data

 

 

 

DownloadNewsFeedData downloadNewsFeedData = new DownloadNewsFeedData(GetNewsFeedDataTable);

 

 

 

 

AsyncCallback ac = new AsyncCallback(UpdateNewsFeedDownloadingStatus);

 

 

downloadNewsFeedData.BeginInvoke(companyNewsFeedURL, ac, downloadNewsFeedData);

 

 

 

 

 

}

 

 

 

catch (Exception ex)

 

 

{

 

 

 

}

 

}

#endregion

#region

 

 

Private Routines

 

 

 

 

/// <summary>

 

 

 

/// It will be called when news downloading thread is completed

 

 

 

/// </summary>

 

 

 

/// <param name="ar">Result object of the async thread</param>

 

 

 

private void UpdateNewsFeedDownloadingStatus(IAsyncResult ar)

 

 

{

 

 

 

try

 

{

 

 

//Bind news feed data table to the grid

 

RadGridNewsFeed.DataSource = _dsNewsFeed.Tables[

 

"item"];

 

 

RadGridNewsFeed.DataBind();

 

 

 

//Terminate exchange rate downloading request

 

 

 

DownloadNewsFeedData downloadNewsFeedData = (DownloadNewsFeedData)ar.AsyncState;

 

 

 

 

if (!object.Equals(null, downloadNewsFeedData))

 

 

downloadNewsFeedData.EndInvoke(ar);

 

 

 

}

 

 

 

catch (Exception ex) { }

 

 

}

 

 

 

/// <summary>

 

 

 

/// It will download the feed from third party server and bind it to the grid

 

 

 

/// </summary>

 

 

 

/// <param name="newsFeedURL">Third party web service url to download the feed</param>

 

 

 

private void GetNewsFeedDataTable(string newsFeedURL)

 

 

{

 

 

 

 

 

if (txtLastUrl.Value != newsFeedURL)

 

 

{

 

txtLastUrl.Value = newsFeedURL;

 

 

 

// Create the web request

 

 

 

HttpWebRequest request = WebRequest.Create(newsFeedURL) as HttpWebRequest;

 

 

request.Timeout = 10000;

 

 

 

// Get response

 

 

 

using (HttpWebResponse response = request.GetResponse() as HttpWebResponse)

 

 

{

 

 

 

 

 

// Load data into a dataset

 

_dsNewsFeed.ReadXml(response.GetResponseStream());

 

 

//LogUtility.BuildNewExceptionAndLog(this.GetType(), "GetNewsFeedDataTable", "After get response" + _dsNewsFeed.Tables["item"].Rows.Count.ToString());

 

}

 

 

//RadGridNewsFeed.DataSource = _dsNewsFeed.Tables["item"];

 

 

 

//RadGridNewsFeed.DataBind();

 

}

}

#endregion

#region

 

 

Grid Events

 

 

 

 

/// <summary>

 

 

 

/// It is called after an item is bound to the grid

 

 

 

/// </summary>

 

 

 

/// <param name="sender">The caller of the method. In this case it will be grid</param>

 

 

 

/// <param name="e">It contains the parameter information which is passed along the event</param>

 

 

 

protected void RadGridNewsFeed_ItemDataBound(object sender, GridItemEventArgs e)

 

 

{

 

 

 

if (e.Item.ItemType == GridItemType.AlternatingItem || e.Item.ItemType == GridItemType.Item)

 

 

{

 

 

 

GridDataItem gItem = (GridDataItem)e.Item;

 

 

 

 

DataRowView dr = e.Item.DataItem as DataRowView;

 

 

 

 

if (dr.Row["description"] != DBNull.Value || !string.IsNullOrEmpty(dr.Row["description"].ToString()))

 

 

{

 

gItem.ToolTip = dr.Row[

 

"description"].ToString();

 

 

}

 

}

 

}

#endregion

 

 

protected void btnReload_Click(object sender, EventArgs e)

 

 

{

 

 

 

this.LoadNewsFeed();

 

 

}

 

 

 

protected void RadGridNewsFeed_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)

 

 

{

 

 

 

try

 

{

 

 

////Bind news feed data table to the grid

 

 

 

//if (_dsNewsFeed != null && _dsNewsFeed.Tables.Count > 0)

 

 

 

// RadGridNewsFeed.DataSource = _dsNewsFeed.Tables["item"];

 

 

 

//else

 

 

 

// RadGridNewsFeed.DataSource = null;

 

}

 

 

catch (Exception ex) { }

 

 

}

 

}


I tried attaching code but it is not allowed :(
Thanks in anticipation.
Asim
Top achievements
Rank 1
 answered on 26 Apr 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?