Telerik Forums
UI for ASP.NET AJAX Forum
8 answers
262 views
Hello again!

I'm trying to visualize a very intensive double for-loop piece of code. The story is that there are a number of job I need to process. Say 200 jobs. For each job, i need to go through a list of workers I have, say 500. There are criteria (address, max distance from job, job type) that shortlist the workers to some extent before the inner for-each worker loop starts.

So I have a total progress (Total number of jobs) and a secondary progress for each primary unit. I need to get the RadProgressManager + RadProgressArea working here. I used a tutorail and some forum help to get the basics up but the behaviour is not what I accepted. The only thing that is visualizing is the time elapsed thing and the rest of the control just remains still. no progress bar movement at all.

Currently, the function is taking around 7 minutes to solve 250 jobs. The function has room for improvement, no doubt, but for now, I just need my user(s) to know something is happening and how far along is it.

Thanks.

Code:
protected void Page_Load(object sender, EventArgs e) {
  if (Page.IsPostBack == false) {
 
    if (HasJobsToBook()) {
      FinalSolution.Rows.Clear();
      RetrieveJobsToBookBatchIDs();
      long iCount = RetrieveActualJobsAgainstBatchIDs();
      PreSortTheJobs(iCount);
 
      LabelError.Visible = true;
      LabelError.Text = String.Format("I have {0} job(s) to process!", iCount);
 
      RadProgressAreaGenie.ProgressIndicators &= ~ProgressIndicators.SelectedFilesCount;
    }
 
  }
 
  RadProgressAreaGenie.Localization.Uploaded = "Total Progress";
  RadProgressAreaGenie.Localization.UploadedFiles = "Progress";
  RadProgressAreaGenie.Localization.CurrentFileName = "Job Genie in action!";
}
 
private void MatchALocum() {
  LabelError.Visible = false;
  LabelError.Text = string.Empty;
 
  if (CountOfJobsToBook() < 1) {
    LabelError.Visible = true;
    LabelError.Text = "No job(s) to process.";
    Trace.Warn("Job Genie", "No job(s) to process.");
    return;
  }
 
  RadProgressContext progress = RadProgressContext.Current;
  progress.Speed = "N/A";
 
  try {
 
    #region Declerations
 
    int iCounterControl = 0;
    int iCounterControlInner = 0;
 
    foreach (DataRow Row in TableJobsToBook.Rows) {
      iCounterControl = iCounterControl + 1;
 
      progress.PrimaryTotal = TableJobsToBook.Rows.Count;
      progress.PrimaryValue = iCounterControl;
      progress.PrimaryPercent = (iCounterControl / TableJobsToBook.Rows.Count) * 100;
 
      if (!Response.IsClientConnected) {
        //Cancel button was clicked or the browser was closed, so stop processing
        break;
      }
 
      #region Key Extracted Job Properties
 
      #region Availability
 
      #region Distance Preperation
 
      iCounterControlInner = 0;
 
      foreach (long ListOfCandidateLocumID in ListOfCandidateLocumIDs) {
        iCounterControlInner = iCounterControlInner + 1;
 
        progress.SecondaryTotal = ListOfCandidateLocumIDs.Count();
        progress.SecondaryValue = iCounterControlInner;
        progress.SecondaryPercent = (iCounterControlInner / ListOfCandidateLocumIDs.Count()) * 100;
 
        progress.CurrentOperationText = "Step " + iCounterControlInner.ToString();
 
        //Massive + Intensive code here...
 
        //Stall the current thread for 0.1 seconds
        System.Threading.Thread.Sleep(100);
         
      }//For Loop Candidates
 
 
      progress.TimeEstimated = (TableJobsToBook.Rows.Count - iCounterControl) * 100;
       
      //Stall the current thread for 0.1 seconds
      System.Threading.Thread.Sleep(100);
 
    }//For Loop Jobs
 
  } catch (Exception ex) {
    Trace.Warn("Job Genie", "Exception:" + ex.Message);
    throw new Exception("Error while running Job Genie.", ex);
  }
}

HTML:
<telerik:RadProgressManager ID="RadProgressManagerGenie" runat="server" Skin="Office2007" />
<telerik:RadProgressArea ID="RadProgressAreaGenie" runat="server" Skin="Office2007" Culture="(Default)"
  ProgressIndicators="TotalProgressBar, TotalProgress, TotalProgressPercent, FilesCountBar, FilesCount, FilesCountPercent, SelectedFilesCount, CurrentFileName, TimeElapsed, TimeEstimated"
  Width="100%">
  <Localization Uploaded="Uploaded" />
</telerik:RadProgressArea>

Thanks.
Genady Sergeev
Telerik team
 answered on 27 Jan 2011
1 answer
210 views
Hello,
I am having an issue with a RadGrid that allows users to insert and edit records with a modal window, e.g. EditMode - Modal, where the loading panel on the RadGrid covers the modal window, e.g. has what seems to be a higher z-index.  See the attachment to this post for an example of the issue in the form of a screenshot.

The RadGrid is ajaxified any associated with a RadAjaxManager with a loading panel specified.
<telerik:AjaxSetting AjaxControlID="radgrid1">
    <UpdatedControls>
        <telerik:AjaxUpdatedControl ControlID="radgrid1" LoadingPanelID="LoadingPanel1" />
    </UpdatedControls>
</telerik:AjaxSetting>

When the user inserts or edits a record on the RadGrid the modal pop-up displays along with the loading panel, however for the period of time that the loading panel displays it appears over the modal.  I have tried changing the z-index of the modal to 91000, but even that does not work (I am not sure if the number is not high enough.

How can I ensure that the modal window appears above the loading panel (z-index wise)?  What is the z-index of the loading panel by default?
Maria Ilieva
Telerik team
 answered on 27 Jan 2011
3 answers
80 views

Hi,

Telerik features in our application have not been upgraded since the launch of the system (2003), and our users have cited that these functions are not user friendly and lack functionality in comparison to features available in Word.
  - RadEditor Version = 5.6.4.0
  - RadSpell.dll Version = 2.6.1.0

As we upgrade our applicaction to .net Framework 3.5, I am performing feasibility study of updating to see if the following items could be resolved ot added.

Our Issues:

  1.     Bullet function is not working properly in that “round” bullets are displayed but “dashes” print out. 
  2.     Users also found that Spell-check picked up too broad of a range of possible hits, and although it appeared that we once had the ability to customize the spell-check dictionary, since the .net upgrade this ability appears to be no longer accessible.
  3.     Users have also expressed an interest in being able to access a highlight feature. Is it possible to access this feature within telerik and if this feature can be selectively turned on/off on the toolbar associated to the various text boxes.

I would appreciate your help on the above questions. Would you also please let me know which version of Telerix is needed to be downloaded to gain 3 above functionalities. Is theer any othe components is needed?Also could you please let me know if I need to change the code or not?


Thank you inadvance for your help.

 

Rumen
Telerik team
 answered on 27 Jan 2011
10 answers
416 views
Hi,

I have an idea in my head about a grid layout but I need assistance in figuring out how I can implement that. This is regarding a column called status.

The status dropdown would have fixed values (say Activate, Deactivate, Suspended etc. and the values will not be full text but char like A, D, S). When the grid is databound, the status dropdown value will be selected to the record's status. The user will have the option to change the status of the record by choosing another value in the dropdown. On change, data will be posted back and database will be updated with the new status for the record.

On top, I have the grid enabled for filtering. For this column, the filtering will have the dropdown and when user chooses a particular status, the grid should filter the records to only the records with that status.

I'm not sure how I can do this because I'm just starting on RadGrid. Can anyone help me figure out how to make this possible? I would really appreciate it.

Kind Regards,
JB
Tsvetina
Telerik team
 answered on 27 Jan 2011
3 answers
234 views
Hi,

first of all i would like to thank you guys for this very nice component.
I remember how i spent at least 3 months to implement a Self-referencing Hierarchy radgrid
with inline edit. It was really though and almost a nightmare.
When i saw this new component, i was like, omg finally they did it!
Well almost, because a lot of feature are still missing now...

I know the features will come later in the next release hopefully, probably between february and march,
but i can not wait and have to launch our website already in february.

Well, i have a treelist with 2 columns, a boundcolumn and a templatecolumn.
The templatecolumn is a radnumerictextbox.
Now, i can enter some value in each radnumerictextbox inside the templatecolumn.
So far so good.
Now my problem: how to retrieve all these value and save them when the user clicks
on a save button?

Please tell me it's possible riht now or you have maybe already done a lab for that or
can attach some demo example.

I tried again with Self-referencing Hierarchy radgrid but it's "buggy" and i don't want to mess
again with all the issues i had last time.

Thank you very much for your help and assistance.
Lucien
Radoslav
Telerik team
 answered on 27 Jan 2011
2 answers
241 views
Hi All,
        I am using RadCombobox and I have to get selectedValue of radComboBox using frm.Page.Request["radCmbID"].

Previously
    The request object with asp:DropDown  is giving correct output i.e. it gives selectedValue of asp:DropDown.

eg- string defaultval = FRM.Page.Request["ASPDropID_drp"];    --- gives selectedValue.

But above code is fail for RadCombobox, If I used same code for radCombo it will give "selectedText".
So how can I get "selectedValue" of RadCombobox using "Request[]" Object ??????

Its very urgent...
waiting for reply...
Shinu
Top achievements
Rank 2
 answered on 27 Jan 2011
1 answer
121 views
Hi,

I was just wondering if it is possible to have a border over Line Chart series ? 

I can set the appearance for Line and it modifies the Line based on Solid, Dash, Dot etc fills... Can I have a Solid line with a border defined with a different color ?
Evgenia
Telerik team
 answered on 27 Jan 2011
1 answer
306 views
I installed Telerik.Web.UI_2010_3_1317_Trial and Telerik_AJAK_controls_2010_3_1317_for_SharePoint_2010_Trial. I have a Visual Web Part Project with a reference to Telerik.Web.UI for .NET 3.5 and some controls. When I debug this project and I try to add the web part to a page, I get this parse error:

Could not load file or assembly 'Telerik.Web.UI' or one of its dependencies. The system cannot find the file specified.
Line 9:  <%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>
I've checked Windows/assembly for the dll's and they're present. I was also getting this error before I ran the SP installer.
Georgi Tunev
Telerik team
 answered on 27 Jan 2011
2 answers
308 views
When you have a asp.net textbox control defined in RadInputManager as TextBoxSetting and

If you disable the textbox control client-side prior to postback, the value is lost on postback.

Consider the following code:
<%@ Page Language="C#" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
  
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
 
<script runat="server">
 
    protected void btnGo_Click(object sender, EventArgs e)
    {
        Response.Write(tbPayeeLine1.Text);
    }
</script>
 
<head id="Head1" runat="server">
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<title>RadControls for ASP.NET AJAX</title>
      
</head>
<body>
<form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server" />
  
<telerik:RadInputManager ID="RadInputManager1" runat="server">
 
    <telerik:TextBoxSetting BehaviorID="PayeeLine1Behavior" EmptyMessage="Enter Payee / Beneficiary Name Here" ErrorMessage="Payee/Beneficiary Required"
        Validation-IsRequired="true" Validation-ValidationGroup="ValGrpPayeeInfo">
        <TargetControls>
            <telerik:TargetInput ControlID="tbPayeeLine1" />
        </TargetControls>
    </telerik:TextBoxSetting>
    
</telerik:RadInputManager>
 
<asp:TextBox ID="tbPayeeLine1" name="payee" runat="server" MaxLength="33" Width="300px" />
<asp:Button ID="btnDisable" runat="server" Text="Disable" OnClientClick="DisableTextBox();return false;"></asp:Button>
<asp:Button ID="btnGo" runat="server" Text="Go" onclick="btnGo_Click"></asp:Button>
 
<script type="text/javascript">
 
    function DisableTextBox() {
        debugger;
        var tb = $find("<%= RadInputManager1.ClientID %>").get_targetInput("<%= tbPayeeLine1.ClientID %>");
        //tb.disable()
        alert(tb.get_value());
        document.getElementById('<%= tbPayeeLine1.ClientID%>').disabled = true;
    }
  
</script>
  
</form>
</body>
</html>

Pavel
Telerik team
 answered on 27 Jan 2011
3 answers
79 views
Howdy,

I have the MOSSRadEditor installed in my WSS3 environment, so far so good. Is there a way to specify where all uploaded images can be saved to? I don't want to give the user the option to upload them anywhere, just to a folder I specify.

Thanks!
Stanimir
Telerik team
 answered on 27 Jan 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?