Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
336 views
More Information:
It is reproducible when run under IIS.  Works fine during development while running under VS2010.  Thanks.


I am getting InsecureExternalStyleSheetException while running Telerik's control in webform:

[InsecureExternalStyleSheetException: The style sheet '/Styles/Site.css' is not located in any of the 'Style Sheet' folders designated in the web.config.] 
Telerik.Web.UI.ExternalStyleSheetUtils.ResolveSecurePath(String styleSheetRelativePath) +386
Telerik.Web.UI.StyleSheetReference.GetScriptEntry() +363
Telerik.Web.UI.RadStyleSheetManager.RegisterValidStyleSheets(IList`1 styleSheets) +84
Telerik.Web.UI.RadStyleSheetManager.Page_PreRenderComplete(Object sender, EventArgs e) +172
System.EventHandler.Invoke(Object sender, EventArgs e) +0
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +4543


Below is the app setting in my web.xml:
    <appSettings>
        <add key="Telerik.ScriptManager.TelerikCdn" value="Enabled" />
        <add key="Telerik.StyleSheetManager.TelerikCdn" value="Auto" />
        <add key="Telerik.Web.UI.StyleSheetFolders" value="~/Styles/;~" />
        <add key="Telerik.EnabledEmbedSkins" value="false" />
        <add key="Telerik.Skin" value="AuraGlass"/>
    </appSettings>

Simon
Telerik team
 answered on 30 Nov 2011
1 answer
67 views
Hi all,

We have a requirement based on 'network bussiness' where the all registered users structure should be  in Tree View such as i attached below screen shot.
For each Main(parent) user two sub users(child) Left & Right, and for each left user should have again 2 users, right user should have 2 users same left and right, All this i need dynamically.
For Eg: If A user is registered in our site and 'A' user will refer two users like B & C, so that B & C users will be registered under 'A' user.
Hope you understood my scenario and reply me soon, for this type of requirement do we have any controls? How do i proceed ?
Please provide some me some stuff for my practice.

Thanks & Regards
SK.Suhail
Kate
Telerik team
 answered on 30 Nov 2011
3 answers
102 views
Hi,
    I am using rad tool tip manager to enable it in particular rad charts in the page. But it enables for all rad controls other than charts. My requirement is to set it enable only for few chart controls. I added my chart control IDs in the target controls collection of the tool tip manager. Now other controls stopped to response to the tool tip; But in rad charts, the tool tip is not populating correctly and it shows as small circle near the point. Also regular tool tip is displaying with this rad tool tip on mouse over. Is there any solution to get it clear ?
Regards
Shafi
Tsvetie
Telerik team
 answered on 30 Nov 2011
4 answers
76 views
Good morning guys and happy Thanksgiving,
I have two DataGrid on my aspx page and both of them exporting to PDF.First DataGrid working without any problem but the second one header columns not exporting to pdf:

<

 

telerik:RadGrid ID="PrnHistoryGrid" runat="server"

 

 

GridLines="None" AllowPaging="true" AllowSorting="true" OnExcelMLExportRowCreated="PrnHistoryGrid_ExcelMLExportRowCreated" OnExcelMLExportStylesCreated="PrnHistoryGrid_ExcelMLExportStylesCreated" OnItemCreated="PrnHistoryGrid_ItemCreated" OnNeedDataSource="PrnHistoryGrid_NeedDataSource" OnPdfExporting="PrnHistoryGrid_PdfExporting" OnSortCommand="PrnHistoryGrid_SortCommand" >

 

 

<ExportSettings FileName="PrnHistoryData" OpenInNewWindow="true" IgnorePaging="true" ExportOnlyData="true">

 

 

<Excel Format="ExcelML" FileExtension="xls"/>

 

 

<Pdf FontType="Subset" AllowPrinting="true" PaperSize="Letter" />

 

 

</ExportSettings>

 

 

<MasterTableView AutoGenerateColumns="false" >

 

 

 

<RowIndicatorColumn>

 

 

<HeaderStyle Width="70px" />

 

 

</RowIndicatorColumn>

 

 

<ExpandCollapseColumn>

 

 

<HeaderStyle Width="70px" />

 

 

</ExpandCollapseColumn>

 

 

 

<Columns>

 

 

<telerik:GridBoundColumn HeaderText="Req No" DataField="TRKNO" UniqueName="TRKNO" ReadOnly="True" SortExpression="TRKNO" HeaderButtonType="TextButton" >

 

 

<HeaderStyle Width="3px" />

 

 

<ItemStyle Width="3px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Job" DataField="JOB" UniqueName="JOB" ReadOnly="True" SortExpression="JOB" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="3px" />

 

 

<ItemStyle Width="3px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Pgm No" DataField="PGMNO" UniqueName="PGMNO" ReadOnly="True" SortExpression="PGMNO" HeaderButtonType="TextButton" >

 

 

<HeaderStyle Width="2px" />

 

 

<ItemStyle Width="2px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Pgm loc" DataField="PGMLOC" UniqueName="PGMLOC" ReadOnly="True" SortExpression="PGMLOC" HeaderButtonType="TextButton" >

 

 

<HeaderStyle Width="5px" />

 

 

<ItemStyle Width="5px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Service StDate" DataField="STDATE" UniqueName="STDATE" DataFormatString="{0:MM/dd/yyyy}" ReadOnly="true" SortExpression="STDATE" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="15px" />

 

 

<ItemStyle Width="15px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Service EndDate" DataField="ENDDATE" UniqueName="ENDDATE" DataFormatString="{0:MM/dd/yyyy}" ReadOnly="true" SortExpression="ENDDATE" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="15px" />

 

 

<ItemStyle Width="15px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Req Hrs" DataField="REQHRS" UniqueName="REQHRS" ReadOnly="true" SortExpression="REQHRS" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="5px" />

 

 

<ItemStyle Width="5px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Paid Hrs" DataField="YTDHRS" UniqueName="YTDHRS" ReadOnly="true" SortExpression="YTDHRS" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="5px" />

 

 

<ItemStyle Width="5px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Paid Mins" DataField="YTDMINS" UniqueName="YTDMINS" ReadOnly="true" SortExpression="YTDMINS" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="5px" />

 

 

<ItemStyle Width="5px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Rec Stat" DataField="STATUS" UniqueName="STATUS" ReadOnly="true" SortExpression="STATUS" HeaderButtonType="TextButton" >

 

 

<HeaderStyle Width="1px" />

 

 

<ItemStyle Width="1px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Req Date" DataField="SENDDATE" UniqueName="SENDDATE" DataFormatString="{0:MM/dd/yyyy}" ReadOnly="true" SortExpression="SENDDATE" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="15px" />

 

 

<ItemStyle Width="15px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Stat of Req" DataField="STATUSF" UniqueName="STATUSF" ReadOnly="true" SortExpression="STATUSF" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="1px" />

 

 

<ItemStyle Width="1px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Approved Date" DataField="APPRDATE" UniqueName="APPRDATE" DataFormatString="{0:MM/dd/yyyy}" ReadOnly="true" SortExpression="APPRDATE" HeaderButtonType="TextButton">

 

 

<HeaderStyle Width="10px" />

 

 

<ItemStyle Width="10px" />

 

 

</telerik:GridBoundColumn>

 

 

<telerik:GridBoundColumn HeaderText="Approver Id" DataField="APPRNAME" UniqueName="APPRNAME" ReadOnly="true" SortExpression="APPRNAME" HeaderButtonType="TextButton" >

 

 

<HeaderStyle Width="70px" />

 

 

<ItemStyle Width="70px" />

 

 

</telerik:GridBoundColumn>

 

 

 

</Columns>

 

 

</MasterTableView>

 

 

<ClientSettings EnableRowHoverStyle="True">

 

 

</ClientSettings>

 

 

 

 

</telerik:RadGrid>

 


This is my code:

bool

 

IsExport1 = false;

 

 

protected void btnExporttoPdf1_Click(object sender, EventArgs e)

 

{

 

RadGrid HistoryGrid = (RadGrid)PrnHistoryReport.FindItemByValue("HistoryData").FindControl("PrnHistoryGrid");

 

HistoryGrid.DataSource = Session[

"PrnHistoryRecord"];

 

HistoryGrid.DataBind();

IsExport1 =

true;

 

HistoryGrid.MasterTableView.BorderStyle =

BorderStyle.None;

 

HistoryGrid.MasterTableView.GridLines =

GridLines.Vertical;

 

HistoryGrid.MasterTableView.Columns[0].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[1].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[2].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[3].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[4].HeaderStyle.Width =

Unit.Pixel(55);

 

HistoryGrid.MasterTableView.Columns[5].HeaderStyle.Width =

Unit.Pixel(55);

 

HistoryGrid.MasterTableView.Columns[6].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[7].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[8].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[9].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[10].HeaderStyle.Width =

Unit.Pixel(55);

 

HistoryGrid.MasterTableView.Columns[11].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[12].HeaderStyle.Width =

Unit.Pixel(40);

 

HistoryGrid.MasterTableView.Columns[13].HeaderStyle.Width =

Unit.Pixel(40);

 

 

HistoryGrid.MasterTableView.ExportToPdf();

 

}

Seems like data is exporting but not header columns.

Thanks so much for your help.
Iana Tsolova
Telerik team
 answered on 30 Nov 2011
1 answer
177 views

Our webapplication throws multiple exceptions at every request.

System.Web.HttpException (0x80004005): This is an invalid webresource request.
at System.Web.Handlers.AssemblyResourceLoader.System.Web.IHttpHandler.ProcessRequest(HttpContext context)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)


The application is installed on a Windows 2008 Server with IIS7.

  <system.web>
      <siteMap defaultProvider="InPageSiteMap">
          <providers>
              <clear/>
              <add name="InPageSiteMap" type="Wervis.Business.Services.InPage.InPageStaticSiteMapProvider"/>
          </providers>
      </siteMap>
  <customErrors mode="Off" defaultRedirect="~/Error">
    <error statusCode="404" redirect="~/NotFound"/>
    <error statusCode="500" redirect="~/Error"/>
  </customErrors>
      <compilation debug="true" targetFramework="4.0">
          <assemblies>
              <add assembly="Telerik.Web.UI"/>
              <add assembly="System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
              <add assembly="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
              <add assembly="System.Drawing.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
              <add assembly="System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
              <add assembly="System.Speech, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/></assemblies>
      </compilation>
      <authorization>
          <allow users="*"/>
      </authorization>
 
      <pages maintainScrollPositionOnPostBack="true">
          <controls>
              <add tagPrefix="telerik" namespace="Telerik.Web.UI" assembly="Telerik.Web.UI"/>
              <add tagPrefix="Wervis" namespace="Wervis.InPage.Web.Controls" assembly="Wervis.InPage.Web.Controls"/>
              <add tagPrefix="EventOn" namespace="EventOn.Controls.Event" assembly="EventOn.Controls.Event"/>
          </controls>
      </pages>
  <!-- Start offline, used by IIS6 --><!--
      <httpHandlers>
          <add path="Telerik.RadUploadProgressHandler.ashx" type="Telerik.Web.UI.RadUploadProgressHandler" verb="*" validate="true"/>
          <add path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler" verb="*" validate="false"/>
          <add path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler" verb="*" validate="false"/>
          <add path="ChartImage.axd" type="Telerik.Web.UI.ChartHttpHandler" verb="*" validate="false"/>
          <add path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" validate="false"/>
      </httpHandlers>
      <httpModules>
          <add name="Wervis.HttpModule.InPage" type="Wervis.HttpModule.InPage.Rewriter,Wervis.HttpModule.InPage"/>
          <add name="RadCompression" type="Telerik.Web.UI.RadCompression"/>
          <add name="RadUploadModule" type="Telerik.Web.UI.RadUploadHttpModule"/>
      </httpModules>
  --><!-- End offline, used by IIS6 -->
   
      <webServices >
          <protocols >
              <add name="HttpGet" />
          </protocols >
      </webServices>
      <httpRuntime useFullyQualifiedRedirectUrl="false" maxRequestLength="40960" executionTimeout="45" />
  </system.web>
 
<!-- Used by IIS7 -->
  <system.webServer>
      <validation validateIntegratedModeConfiguration="true"/>
      <modules>
          <remove name="RadUploadModule"/>
    <add name="RadUploadModule" type="Telerik.Web.UI.RadUploadHttpModule" preCondition="integratedMode"/>
          <remove name="RadCompression"/>
    <add name="RadCompression" type="Telerik.Web.UI.RadCompression" preCondition="integratedMode"/>
    <add name="Wervis.HttpModule.InPage" type="Wervis.HttpModule.InPage.Rewriter,Wervis.HttpModule.InPage" preCondition="integratedMode"/>       
      </modules>
      <handlers>
    <remove name="ScriptResource"/>
    <add name="ScriptResource" path="ScriptResource.axd" verb="GET,HEAD" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" preCondition="integratedMode"  />
    <remove name="*_AppService.axd_"/>
    <add name="*_AppService.axd_*" path="*_AppService.axd" verb="*" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" preCondition="integratedMode,runtimeVersionv4.0"/>
    <remove name="*.asmx_*"/>
    <add name="*.asmx_*" path="*.asmx" verb="*" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" preCondition="integratedMode,runtimeVersionv4.0"/>
 
    <remove name="ChartImage_axd"/>  
          <add name="ChartImage_axd" path="ChartImage.axd" type="Telerik.Web.UI.ChartHttpHandler" verb="*" preCondition="integratedMode"/>
    <remove name="Telerik_Web_UI_SpellCheckHandler_axd"/>
    <add name="Telerik_Web_UI_SpellCheckHandler_axd" path="Telerik.Web.UI.SpellCheckHandler.axd" type="Telerik.Web.UI.SpellCheckHandler" verb="*" preCondition="integratedMode"/>
    <remove name="Telerik_Web_UI_DialogHandler_aspx"/>
    <add name="Telerik_Web_UI_DialogHandler_aspx" path="Telerik.Web.UI.DialogHandler.aspx" type="Telerik.Web.UI.DialogHandler" verb="*" preCondition="integratedMode"/>
    <remove name="Telerik_RadUploadProgressHandler_ashx"/>
    <add name="Telerik_RadUploadProgressHandler_ashx" path="Telerik.RadUploadProgressHandler.ashx" type="Telerik.Web.UI.RadUploadProgressHandler" verb="*" preCondition="integratedMode"/>
    <remove name="Telerik_Web_UI_WebResource_axd"/>
    <add name="Telerik_Web_UI_WebResource_axd" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" preCondition="integratedMode"/>
      </handlers>
  </system.webServer>


We think the exceptions are related to the Telerik embedded resources. Can anyone help us to solve this problem?


Shinu
Top achievements
Rank 2
 answered on 30 Nov 2011
4 answers
175 views
This sounded like such a simple request but I simply can't figure it out.

I want to prevent the user from selecting certain file types (I'm trying to implement a blacklist type of validation rather than the whitelist method that the telerik control comes with out-of-the-box).

OK, so there's no set_cancel() method for OnClientFileSelected. A shame, but moving on.

I though, OK, if they select an invalid file type, I'll just remove it, so came up with this ....
var fileExtensionBlacklist = "<%=DisallowedFileTypes %>";
function OnClientFileSelected(sender, e)
{
    if("<%=UseBlacklist %>" == "True")
    {
        var selectedFileName = e.get_fileName();
        var selectedExtension = selectedFileName.split(".").pop();
        if (fileExtensionBlacklist != "" && fileExtensionBlacklist.indexOf(selectedExtension) > -1)
        {
            try { $find("<%=RadAsyncUpload1.ClientID %>").deleteFileInputAt(e.get_rowIndex()); } catch (ex) { }
        }
    }
}
function OnClientFileUploadFailed(sender, e)
{
    e.set_handled(true);
}
This doesn't work, the attempt to delete the file input generates an error reporting "HtmlPage_NotEnabled" in a line of javascript that calls Content.Page.MarshalUploads(). This appears to be something to do with Silverlight, but I can't stop it from happening.

Working to a deadline, I moved on.

So, I thought, "OK, if I can't stop 'em selecting these files, I can at least, stop 'em from being uploaded".

So, I modified the code to this ...
function OnClientFileUploading(sender, e)
{
    if("<%=UseBlacklist %>" == "True")
    {
        var selectedFileName = e.get_fileName();
        var selectedExtension = selectedFileName.split(".").pop();
        if (fileExtensionBlacklist != "" && fileExtensionBlacklist.indexOf(selectedExtension) > -1)
        {
            e.set_cancel(true);
        }
    }
}
Tried that and Yay! the file is mared red as a failed upload!

Then I click on the button on my page to actually do the postback and process the uploaded files. Get what I find in my server-side list of uploaded files, yep. The file that I had set cancel on. What's more it shows it IsValid as true.

Is this God's punishment for me working on a Sunday? If it is, he's picking on the wrong bloke, I have no choice; he should go smite the guy who said I had to.

If anyone can offer any suggestions as to what I'm doing wrong, I'd love to hear 'em.

--
Stuart


Stuart Hemming
Top achievements
Rank 2
 answered on 30 Nov 2011
1 answer
131 views
I am attempting to create a custom skin for all of the ASP.NET AJAX Controls so that all the controls have a unified look and feel that matches the rest of my site. I have found all of the sprite.gif files inside of C:\Program Files (x86)\Telerik\RadControls for ASP.NET AJAX\Skins, but it seems like a tedious task to take all of these and edit them to fit my color scheme. I have tried on multiple occasions to use the Visual Style Builder to create a custom skin, these endeavors have always ended horribly, that tool simply does not work. Then I found the .psd files located at telerik.com/skins, these seemed to be exactly what I was looking for, I could restyle the entire control at one time, then theoretically slice it up into the sprite.gif files that would work with the css for the control. But this is where I get stuck, once you have the .psd altered the way you want it to look, how then do you convert/slice those into the sprite files that the css will know how to use?

Thanks
Bozhidar
Telerik team
 answered on 30 Nov 2011
2 answers
136 views
Hi,
    I have dragged a rad upload control. When I run my solution I could see all the controls corresponding to Upload. But my "select" button doesnot work. So I am not being able to select any file. Can somebody please help me on this regard?

PFB my code

 

<div>

 

 

 

<telerik:RadProgressManager ID="RadProgressManager1" Runat="server" />

 

 

 

<telerik:RadUpload ID="radUploadFile" Runat="server"

 

 

 

AllowedFileExtensions=".zip" ControlObjectsVisibility="None"

 

 

 

MaxFileInputsCount="1" Skin="WebBlue" TargetFolder="~/Files"

 

 

 

OverwriteExistingFiles="True">

 

 

 

</telerik:RadUpload>

 

 

 

</div>

Thanks,
Kishan

 

 

Ben Hobgood
Top achievements
Rank 1
 answered on 30 Nov 2011
3 answers
133 views
Hi team

Any one have idea regarding raddatepicker history removal please verify the attachment
Princy
Top achievements
Rank 2
 answered on 30 Nov 2011
1 answer
103 views
I am using Radchart with chart type as line, my chart takes time to load, so i want to show a loading panel until the chart loads, to indicate its processing.
Princy
Top achievements
Rank 2
 answered on 30 Nov 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?