Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
154 views
Hi,

Moved the server to a new hosting, after moving the drop down is not working.

When viewed from firebug we are getting the below error

Server Error in '/' Application.

Cannot perform CAS Asserts in Security Transparent methods



Description: An unhandled exception occurred during
the execution of the current web request. Please review the stack trace
for more information about the error and where it originated in the
code.





Exception Details: System.InvalidOperationException: Cannot perform CAS Asserts in Security Transparent methods



Source Error:








An unhandled exception was generated during the execution of the current
web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.








Stack Trace:






[InvalidOperationException: Cannot perform CAS Asserts in Security Transparent methods]
System.Security.CodeAccessSecurityEngine.CheckNReturnSO(PermissionToken permToken, CodeAccessPermission demand, StackCrawlMark& stackMark, Int32 create) +0
System.Security.CodeAccessSecurityEngine.Assert(CodeAccessPermission cap, StackCrawlMark& stackMark) +60
System.Security.CodeAccessPermission.Assert() +28
Telerik.Web.UI.ScriptAssemblyInfo.get_ModifiedTime() +170
Telerik.Web.UI.CombinedScriptWriter.GetLastAssemblyModificationTime() +172
Telerik.Web.UI.CombinedScriptWriter.WriteCombinedScriptFile() +1230
Telerik.Web.UI.WebResource.ProcessRequest(HttpContext context) +74
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +341
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +69











Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.18449               
Bozhidar
Telerik team
 answered on 02 Jun 2014
2 answers
185 views
Hi . 
I have 3 control in a form , 
2  Radcombobox and a button . 
the first radcombobox binded to webservice and the second bind in server side code .
both radcomboboxes have AutoPostback="true" attribute . 
when I choose an item from the first combo the second bind with item that selected from the first combo . 
but I have problem when I choose an item from the second combo and do post back . after post back it seems that the first combo box dose not have any item selected. 
I write a custome validation in clientside code that checked the value of first combo . after second combobox post back the customevalidator return null .
function ClientValidate_<%= this.ClientID %>(source, args) {
            var combo = $find("<%= ExComboControl.ClientID %>");
            if (combo.get_enabled()) {
                args.IsValid = false;
                var text = combo.get_text();
                if (text.length < 1) {
                    args.IsValid = false;
                    combo.set_emptyMessage("Please choose an Item");
                }
                else {
                    combo.trackChanges();
                    console.log(text);
                    var node = combo.findItemByText(text);
                    console.log(node);
                    var inputElement = combo.get_inputDomElement();
                    console.log(inputElement);
                    if (node) {
                        args.IsValid = true
                        args.IsValid = false;
                        inputElement.style.color = "black";
                    }
                    else {
                        args.IsValid = false;
                        inputElement.style.color = "#FF0000";
                    }
                }
            }
        }
 
Shinu
Top achievements
Rank 2
 answered on 02 Jun 2014
5 answers
250 views
Hello,

I've set up an HTMLChart Column Chart.  The tooltips appear on the right of each column when hovering over the column.  For the columns at the far right side of the chart, this means the tooltips are squished and unreadable.  Is there a way to change the position of the tooltips so the ones on the right side of the chart can be fully seen?

Thanks.
Phuong
Top achievements
Rank 2
 answered on 02 Jun 2014
1 answer
122 views
Hi,

I have a combo with check boxes.
When I select only one item and close the combo, I get the name of the item on the combo. Works good.
When I select few items in the combo I get the text "x items checked". Works good.

But... If I select only one item, close the combo (and get the item's name on the combo), then open it again and check few more items, and close the combo, now I still have the name of the first checked one. The text doesn't change to "x items checked".

An image with the steps to reproduce is attached.

Is this a known issue?
Is there a workaround?

Thanks,
Guy.
Princy
Top achievements
Rank 2
 answered on 02 Jun 2014
1 answer
520 views
I have a Radgrid with auto generated columns = "True" and I would like to change the header text programmatically at the Detail table levels when the radgrid loads at page load.  How would I accomplish this?  I figured simply utilizing the code shown below would work, but it doesn't do anything.  The page just loads with no errors, and the text does not change on the header.  However, when I change the text programmatically in the root level of the radgrid it works, but does not work at the detail levels.  Please Help!

'''I tried this code in the PreRender and ItemDataBound Events.  But it does not work. Text does not change.... 

Radgrid_CRGList.MasterTableView.DetailTables(1).DetailTables(0).GetColumn("UniqueName").HeaderText = "Custom Header Text"

Princy
Top achievements
Rank 2
 answered on 02 Jun 2014
3 answers
188 views
When a user selects an item from the drop down, I want to call a method that gets details from a database for the selected item (using the DataValueField).  I have this code

 protected void RadAutoCompleteBox1_EntryAdded(object sender, AutoCompleteEntryEventArgs e)
        {
                AutoCompleteBoxEntry entry = e.Entry;
                
        }

but it never gets fired, I also have this set

AutoPostBack="True"

The dropdown list appears (after typing the first 2 characters)  but I cant trap the selection event, has anyone managed to do this ?
Shinu
Top achievements
Rank 2
 answered on 02 Jun 2014
10 answers
486 views
Is there a way, I can hide the X button when I do Add/Edit in RadGrid in PopUp edit mode? For normal RadWindow, we can customize the behaviours(close, maximize, minimize, resize etc.), same way do we have any control over the behaviours in RadGrid edit mode PopUp window?

Thanks
venu
Top achievements
Rank 1
 answered on 31 May 2014
2 answers
94 views
I have a RadComboBox and other controls, including an ASP Repeater within a RadAjaxPanel.  
The contents of the combo box are fairly typical, a list of numbers with -1 and blank text indicating that nothing has been selected.
The repeater displays a list of bound RadButton check boxes.

If the combo box has a valid value (> 0) selected, the server-side selected index changed event of the combo box calls a routine to repopulate the repeater, 

If the combo box is set to -1 what I would like to happen is for the post back to be canceled and the most recent collection of controls in the repeater (and their checked values) to be retained, and the combo box itself to retain its -1 value.

Is this possible?
Boris
Top achievements
Rank 1
 answered on 30 May 2014
3 answers
130 views
Hi,

I'm using Telerik 2011 Q2 ( file version 2011.2.712.0,  size: 2029840 bytes)


I have the following problem: When the Telerik CDN is enabled  AsyncUpload  fail to show (seems to try to load silverlight even SL plugin is not available), using embedded scripts works fine (load flash when no SL available) but lose CDN benefits.

Comparing the AsyncUpload js file embeded on Telerik dll with the hosted on Telerik CDN both files are different. I was believe will be the identical but not.

Why the file hosted on CDN is different and have errors? 

Where is hosted the right file for my Telerik build? and how force ScriptManager to use it?


Please any advice is welcome.


CDN version:
http://aspnet-scripts.telerikstatic.com/ajaxz/2011.2.712/AsyncUpload/RadAsyncUploadScripts.js

Embeded file:  
https://mega.co.nz/#!NZ0VEQJK!1kSwpohH28IdWrien1PHP6xA9TG0gJZeOnCIhS-96Ls

cannot attach zip files...




Boyan Dimitrov
Telerik team
 answered on 30 May 2014
2 answers
265 views
I am using RadGrid which has both Filter and Pager.
When filtered 3 pages after that I clicked on page 2 then radgrid show page 2 of all data (filter not working at this time)
Sometimes, Filter also did not work properly. I don't know why. Can someone help me now?
_fileRadGrid.MasterTableView.FilterExpression always = empty so I have to use _fileStatusPendingRadGrid.MasterTableView.GetColumnSafe("Status").CurrentFilterValue to check HasFilter.

When I reload the page then pager and filter are not working properly. (I also code for another web app with filter and pager are working fine)
Please tell me why that code not working? the version of telerik is 2014.1.225.45

Inline:
<telerik:RadGrid ID="_fileRadGrid" runat="server" AutoGenerateColumns="False" AllowSorting="False"  
        AllowPaging="true" AllowFilteringByColumn="True" EnableAJAX="True" EnableViewState="True" ViewStateMode="Enabled"
        EnableEmbeddedSkins="False" EnableEmbeddedBaseStylesheet="False" Skin="NitroCleo" PageSize="10" EnableLinqExpressions="False"
        OnNeedDataSource="FileNeedDataSource"
        OnItemDataBound="FileItemDataBound">        
        <ClientSettings>
            <clientevents ongridcreating="OnGridCreated"/>
        </ClientSettings>
        <MasterTableView DataKeyNames="FileIdentifier" ClientDataKeyNames="FileIdentifier"
            NoMasterRecordsText="No file" AllowFilteringByColumn="True" >
            <PagerStyle Mode="NextPrevAndNumeric" PageButtonCount="6" />
            <Columns>
                <telerik:GridTemplateColumn HeaderStyle-Width="25px" AllowFiltering="False">
                    <ItemTemplate>
                        <asp:Label ID="_iconLabel" runat="server"></asp:Label>
                    </ItemTemplate>
                    <ItemStyle HorizontalAlign="Center"></ItemStyle>
                </telerik:GridTemplateColumn>
                <telerik:GridTemplateColumn HeaderText="Status" UniqueName="Status" DataField="Status" AutoPostBackOnFilter="True"
                    CurrentFilterFunction="Contains">
                    <ItemTemplate>
                        <asp:HyperLink runat="server" ID="_statusLink"></asp:HyperLink>
                    </ItemTemplate>
                </telerik:GridTemplateColumn>
            </Columns>
        </MasterTableView>
    </telerik:RadGrid>

Code Behind:
        protected void FileNeedDataSource(object sender, GridNeedDataSourceEventArgs e)
        {
            BindFileGrid(true);            
        }

        private void BindFileGrid(bool needDataBind = false)
        {
            var listFile = new List<FileItem>();
            int virtualItemCount = 0;
            int pageSize = 0;
            int pageIndex = 0;

            try
            {
                if (!HasApplyFilter())
                {
                    pageSize = _fileRadGrid.PageSize;
                    pageIndex = _fileRadGrid.CurrentPageIndex;
                }
                _fileRadGrid.AllowCustomPaging = !HasApplyFilter();

                listFile = GetDataSourceForFile(pageIndex, pageSize, out virtualItemCount);
            }
            catch (Exception ex)
            {
                Log.Error(String.Format("An error while get file. Error: {0}", ex.Message));
            }
            
            _fileRadGrid.MasterTableView.PagerStyle.AlwaysVisible = virtualItemCount == 0 ? false : true;    

            if (listFile != null)
            {
                _fileRadGrid.DataSource = listFile;
                _fileRadGrid.VirtualItemCount = virtualItemCount;

                if (!needDataBind)
                {
                    _fileRadGrid.DataBind();
                }
            }
        }

Thanks for your reading!
Pavlina
Telerik team
 answered on 30 May 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?