Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
274 views

I have a databound ComboBox that the application user needs to be able to 'check'.  What need to do is to show the user which entries have already been 'checked', that is I need to be able to programmatically set the checked property of the items in the combobox.  I can id the items to be checked, I just need the code to actually "check" the item.

Here is my code so far:

If item.IsInEditMode Then

Dim indx As Integer = ctlUserCombo.FindItemIndexByText("Test, Sabo")

Dim cmbo As RadComboBox = CType(item.FindControl("ctlUserCombo"), RadComboBox)

Dim cbox As RadComboBoxItem = CType(cmbo.Items(indx), RadComboBoxItem)

cmbo.Items(indx).Enabled = False

So I am able to change the Enabled property to False...what I need to be able to do is set the combobox to "Checked".  However the RadComboBoxItem does not have a 'checked' property.  Anyone know how to get the combo box to show checked = true for individual items in the combobox? 

Thanks.

Princy
Top achievements
Rank 2
 answered on 21 Jun 2011
2 answers
92 views
It's possible change Resources file associate to RadFileExplorer? if yes....how?

ex. from RadEditor.Dialogs.resx to Resource.resx

Thanks
archimede
Top achievements
Rank 1
 answered on 21 Jun 2011
7 answers
168 views
Hi sorry I think I posted about this a while ago, but I can't find it (or the resolution)

http://screencast.com/t/mcJ4tM7K8tGK

The client state of the control remembers the selected dates, but once it re-renders after a postback none of the <td> tags have the rcSelected class applied...I have to hover-over the element to get it to show back up.
Vasil
Telerik team
 answered on 21 Jun 2011
2 answers
82 views
Hi,

I'm using RadAsyncUpload and it's working well for file less that about 4MB, but when I try to upload a larger file the upload fails (I get a red dot next to the filename).  In the Firefox error console I see the following error: "uncaught exception: Error while uploading, HTTP Error code: 302".

The httpRuntime entry in my Web.config is as follows: <httpRuntime executionTimeout="7200" maxRequestLength="1000000/>

I'm using Visual Studio 2008 with C# and ASP.NET 3.5.  Telerik version is 2011.1.315.35.

I see that on this page (http://www.telerik.com/help/aspnet-ajax/asyncupload-troubleshooting.html) error 302 is mentioned, but no suggestions as to what might cause it.

Has anyone encountered this problem before, or know how to fix it?

Thanks
Andrew
Andrew Dixon
Top achievements
Rank 1
 answered on 21 Jun 2011
1 answer
64 views
Hi all,

I need to display the custom attribute values for each appointment in the front calendar display along with the subject?   As of now, all I can see is the subject. any ideas on how I can accomplish this?

Thank you!

Gus
Gus
Top achievements
Rank 1
 answered on 20 Jun 2011
2 answers
81 views
Hi,

I need to pull the values from all the attributes that I have in the sql table onto the advanced form.
I have added the Custom Attributes via CustomAttributeNames string collector.
I can see the fileds on the advanced form but no values are populating the textboxes from the database.

Thank you,
Gus Koutsivitis
Gus
Top achievements
Rank 1
 answered on 20 Jun 2011
2 answers
1.0K+ views

I'm using the RadGrid contro and. In the ItemDataBound method I'm trying to get the value of a cell which is boolean and I'm receiving a FormException was unhandled by user code (String was not recognized asa valid Boolean) Error.

The only fields that get this error are the boolean fields. All other returns the text or integer with no problem. One thing that does happen is if in debug mode and I mouse over the variable I see the variable and the value (locked = false).Also if I don't conver the variable the value rturns as "&nbsp;" which is very strange.

Any reason how i can return a boolean value or what needs to be done so i can get the correct value without the error or &nbsp;?

protected void gridAddendum_ItemDataBound(object sender, GridItemEventArgs e)
        {
            //Is it a GridDataItem
            if (e.Item is GridDataItem)
            {
                //Get the instance of the right type
                GridDataItem dataBoundItem = e.Item as GridDataItem;

                var logid = dataBoundItem["LogId"].Text;
                var deleted = dataBoundItem["Deleted"].Text; // this is a boolean
                var Ownerid = dataBoundItem["OwnerId"].Text;
                var locked = Convert.ToBoolean(dataBoundItem["Locked"].Text); // this is a boolean
            }

        }

 

 

 

 

Simone
Top achievements
Rank 1
 answered on 20 Jun 2011
20 answers
308 views
Hello Telerik Expert,
What I need is when a user clicks on a RadCalendar's date, it will open up a RadScheduler.
To start off with, for the RadScheduler, what I have done is to actually hard code the ID.
But as it interacts with the RadCalendar, what it should do is when a user clicks on a date, it will open up a RadScheduler.
When the user fills in some info for the specific time span, a new ID will be created and stored back to the Database.
So when the user comes back to that date or any other date on a calender to see their schedule, they can see that specific ID's information. How can we do this? Will the RadScheduler automatically create a new ID, etc. on Insert and update the ID's value on update and even delete automatically.

Please advise.

Thank you.
Nate
Top achievements
Rank 1
 answered on 20 Jun 2011
2 answers
223 views
We have a rather large website and everything was working and loading fine. It has been in production for over two years now with constant updates with new pages. Recently we started looking into Silverlight development and after adding a silverlight project and silverlight class library reference to the website solution we started getting this error message on first run. Subsequent page requests run just fine, but the initial run of the project gets this error.

First thing I tried was to upgrade to latest version. Fail.
Next was to remove the system.windows dependency references from the bin and rebuild project. The files controls.data, controls.data.input, controls.navigation regenerated and are still in the bin as they should be. Fail.
Manually created a reference to system.windows and all child dll's. Fail.
Dumped all extra projects from solution and removed project references. Cleaned and rebuilt solution. Fail.

Any help or Idea's would be appreciated.



[code]

Server Error in '/ePikeMiracle' Application.

Could not load file or assembly 'System.Windows, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e' or one of its dependencies. The system cannot find the file specified.

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.IO.FileNotFoundException: Could not load file or assembly 'System.Windows, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e' or one of its dependencies. The system cannot find the file specified.

Source Error:

Line 112:<body runat="server" id="body">
Line 113:    <form id="form1" runat="server">
Line 114:    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
Line 115:    </telerik:RadScriptManager>
Line 116:    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" DefaultLoadingPanelID="RadAjaxLoadingPanel1">

[/code]

Doug
Top achievements
Rank 1
 answered on 20 Jun 2011
2 answers
77 views
Hi Telerik,

I was wondering what the prescribed method is for tracking dynamically created panes. I have been working with RadDockLayout for some time and am wondering if it is possible to write an extension method that gives it the ability to keep track of the Panes on the page?

Let me shed some light on some of my issues:

There are a bunch of splitters and panes on the page. The user resizes them and I need to save the state of the controls through page refresh at this point. I am doing this by firing an ajax event on pane resized and then saving the states of all the panes.

public static void SavePanes()
{
    foreach (KeyValuePair<string, RadPaneSetting> paneState in GetStates<SerializableDictionary<string, RadPaneSetting>>().ToList())
    {
        CormantRadPane pane = Utilities.FindControlRecursive(HttpContext.Current.Handler as Page, paneState.Key) as CormantRadPane;
        Save<RadPaneSetting>(pane);
    }
}

The Utilities.FindControlRecurisve is just that, a recursive implementation of Page.FindControl. It is slow when there are large amounts of controls on the page, and I do not like calling it more than I absolutely have to, but I do not have a nice collection of monitored RadPanes already.

As such, I created a manager class for regenerating my controls.

public class RegenerationManager
    {
        private static readonly ILog Logger = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
 
        private static readonly RegenerationManager instance = new RegenerationManager();
        private RegenerationManager() { }
 
        public static RegenerationManager Instance
        {
            get { return instance; }
        }
 
        private IList<CormantRadPane> _regeneratedPanes;
 
        //Don't monitor RadDockZone or RadDock -- these are handled by RadDockLayout.
 
        public IList<CormantRadPane> RegeneratedPanes
        {
            get
            {
                if (object.Equals(_regeneratedPanes, null))
                {
                    _regeneratedPanes = new List<CormantRadPane>();
                }
 
                return _regeneratedPanes;
            }
        }
 
        /// <summary>
        /// Recreates the page state recursively by creating a control and looking for its known children.
        /// </summary>
        /// <param name="splitter"> Splitter having children added to it. </param>
        private void RegenerateSplitterChildren(RadSplitter splitter)
        {
            Logger.InfoFormat("Initializing splitter children for splitter {0}", splitter.ID);
            foreach (KeyValuePair<string, RadPaneSetting> paneState in RadControlManager.GetStates<SerializableDictionary<string, RadPaneSetting>>().Where(paneState => paneState.Value.ParentID == splitter.ID))
            {
                CormantRadPane pane = new CormantRadPane(paneState.Value);
                RegeneratedPanes.Add(pane);
                splitter.Controls.Add(pane);
                RegeneratePaneChildren(pane);
                InsertSplitBar(splitter);
            }
        }
 
        /// <summary>
        /// Recreates all the dynamically made DockZones.
        /// </summary>
        public void RegenerateDockZones()
        {
            Logger.Info("Regenerating dock zones.");
            foreach (KeyValuePair<string, RadDockZoneSetting> dockZoneState in RadControlManager.GetStates<SerializableDictionary<string, RadDockZoneSetting>>())
            {
                try
                {
                    RadDockZoneSetting dockZoneSetting = dockZoneState.Value as RadDockZoneSetting;
                    if (dockZoneSetting.ID == "RadDockZone1") continue;
                    Logger.Info(String.Format("Loading state data for dock zone with setting ID: {0}", dockZoneSetting.ID));
                    CormantRadDockZone dockZone = new CormantRadDockZone(dockZoneSetting);
                    //CormantRadPane pane = RegeneratedPanes.First(regeneratedPane => regeneratedPane.ID == dockZoneSetting.ParentID);
                    CormantRadPane pane = Utilities.FindControlRecursive(HttpContext.Current.Handler as Page, dockZoneSetting.ParentID) as CormantRadPane;
                    pane.Controls.Add(dockZone);
                }
                catch (Exception exception)
                {
                    System.Diagnostics.Debug.Assert(false, "Error!");
                    Logger.ErrorFormat("Error regenerating dock zones. Reason: {0}", exception.Message);
                }
            }
        }

If you would kindly look at the above "RegeneratedDockZones" function you will see that I have commented out my attempt at regenerating from my own list. While I seem to find the control just fine I noticed a lot of very weird problems occurring with my dashboard after attempting to load from "RegeneratedPanes". Yet, you can see in RegenerateSplitterChildren that I am working with the same pane which was already existing on the page / being recreated upon the splitter.

Do you see anything erroneous with this? Or anything I should be doing differently? I only have need to monitor RadPanes at this point in time, I was hoping this would be rather simple.. 
Sean
Top achievements
Rank 2
 answered on 20 Jun 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
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?