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

First... Happy Independence Day to Bulgaria !!

Now on to the question...

I've been using version 2009_3_1314 of the Telerik Scheduler control and I've run into a javascript error when I switch to a Month view.

The error points to the following code found in Telerik.Web.UI\Scheduler\Views\Month\Model.js:

    _getTimeSlotDomElement : function(rawIndex)
    {
        var element = this._owner.get_element();
        var rowIndex = Math.floor(rawIndex.dayIndex / this.get_weekLength());
        var cellIndex = Math.floor(rawIndex.dayIndex % this.get_weekLength());
        return  $('div.rsTopWrap table.rsContentTable', element)[0].tBodies[0].rows[rowIndex].cells[cellIndex];
    },

It looks as though when I go to open the Jan 2010 month view, the time slot for Feb 1 (which from what I can tell should have a rowindex is set to 5 and a cellindex is set to 1) gets a null value when we are on the last line of this function.

Is there any way to easily correct this issue? Can I in some way modify the Model.js file and have things rebuilt some how?

Thanks as always for all your help,
Greg
T. Tsonev
Telerik team
 answered on 10 Mar 2010
1 answer
108 views
hi

i am using a grid and perfom grid update/insert operations with User Controls,In my user Control i am using a rad upload but when i add ajax manager for grid then radupload in user control doesn't work please help me to perform update and insert with RadUpload in user control that is called by the grid for update or insert.

pleas reply me as soon as possible

Best Regards
Xshan
Veli
Telerik team
 answered on 10 Mar 2010
1 answer
273 views
Hi All,

Ho can i Set Chart Y-axis scale break points.
For example in "Temperature" example on y-axis it is showing starting from 0 tp 50 (0 10 20 30 40 50),

if i want to show same 0 to 50 like (0 5 10 15 20 25 ......) what should i do

Please help me regarding this.



Velin
Telerik team
 answered on 10 Mar 2010
2 answers
180 views
Hi,

I wrote a "small" time registration application using RadGrid and RadNumericTextBox. A registration page would have all the tasks of a user and show a column for each day of the week, each day-task cell contains a RadNumericTextBox control.

The application works perfectly except for one small issue. Performance is dreadful.

The biggest issue that I am running into is the way RadNumericTextBox works.

First of all the 'pure' HTML code of each control turns into about 1k-1.5k of bytes per input box (1 span and 4 input fields), all these html elements contain an id (and input fields have a name) which can be rather long (for example: ctl00_ContentPlaceHolder1_rgUserTasks_ctl00_ctl06_Detail10_ctl04_rntbDay6_ClientState). 

Secondly, each control adds a javascript initialization code at the end of the page. Code like this:
" $create(Telerik.Web.UI.RadNumericTextBox, {"_enableOldBoxModel":false,"_focused":false,"_shouldResetWidthInPixels":true,"clientStateFieldID":"ctl00_ContentPlaceHolder1_rgUserTasks_ctl00_ctl06_Detail10_ctl04_rntbDay5_ClientState","enabled":true,"incrementSettings":{InterceptArrowKeys:true,InterceptMouseWheel:true,Step:1},"maxValue":24,"minValue":0,"numberFormat":{"DecimalDigits":2,"DecimalSeparator":",","CultureNativeDecimalSeparator":",","GroupSeparator":".","GroupSizes":3,"NegativePattern":"-n","NegativeSign":"-","PositivePattern":"n","AllowRounding":true,"KeepNotRoundedValue":false},"styles":{HoveredStyle: ["width:32px;", "riTextBox riHover"],InvalidStyle: ["width:32px;", "riTextBox riError"],DisabledStyle: ["width:32px;", "riTextBox riDisabled"],FocusedStyle: ["width:32px;", "riTextBox riFocused"],EmptyMessageStyle: ["width:32px;", "riTextBox riEmpty"],ReadOnlyStyle: ["width:32px;", "riTextBox riRead"],EnabledStyle: ["width:32px;", "riTextBox riEnabled"],NegativeStyle: ["width:32px;", "riTextBox riNegative"]}}, {"keyPress":disableEnterKey,"valueChanged":function () { changed = true; UpdateTotals(571,5); }}, null, $get("ctl00_ContentPlaceHolder1_rgUserTasks_ctl00_ctl06_Detail10_ctl04_rntbDay5")); "

This is also another 1k-2k of additional size to the page. The 'fun' part is that this initialization code is largely the same for all controls on the page.

Now html size isn't the entire issue. Because each input control actually contains 4 input fields, a post back results in a lot of data. Even if a field is empty, the fact that each name of each input box is roughly 60-100 bytes results in 320-400 bytes per RadNumericTextBox of post data (its actually more because 1 of the fields contains an unused "client state" field).

One User in the application has roughly 40 tasks which results in 40 * 8 (7 days + 1 'remaining') RadNumericTextBox's which in turn results into a page of 1.2Mbyte and 150k post data. Lets just say it takes .NET a while to render the page, then it takes a while for the user to retrieve the page and then it takes a while for the user to post back the page. Making navigation through the application far from ideal. Note that the design of the application requires "easy" input, so row-editing isn't really an option unless this could be started on mouse-over. Editing mostly happens for a day and not so much row (a row is 7 days for a task).

Currently it looks like I will have to dump RadNumericTextBox control in favor of a traditional input field (possibly even a raw-html field) and perhaps add one RadNumericTextBox to the form and show this input box each time the user wants to edit his hours for that day/task.

Is there any other way around this issue?

Regards,

Jerremy
Jerremy
Top achievements
Rank 1
 answered on 10 Mar 2010
1 answer
99 views
hi all,
i've folllowed some of the examples here and managed to insert different formatting in <span> tags into the editor (using editor.fire pastehtml). Right now the formatting appear where the cursor is. Is there a way to insert directly at the end of the content in the editor no matter where the cursor is?
FYI, the contents are not within a div tag, just plain text. thanks in advance.
Rumen
Telerik team
 answered on 10 Mar 2010
5 answers
121 views
Hey,

When my page contains not much data, the splitter works fine. But when the page data increased (no Pagin in Gridview) and I open and close the slidingzonePane, the slidingzonepane won't collapse, it stays open with a white background color!

In attachment you can see 2 pictures:

    Collapsed.jpg: The collapsed slidingzone (correct)
    Collapsed-problem.jpg: The collapsed slidingzone when the page data is to big, it has just a white background and I must reload refresh the page!

Can someone help me?

Thanks,
Jan
Jan Fockaert
Top achievements
Rank 1
 answered on 10 Mar 2010
2 answers
270 views
Guys,
1.    I have a textbox with a tooltip
2.    I have a RadToolTipManager with AutoTooltipify="true" that show that tooltip
3.    I have a  RadComboBox. On clientchange event I need to change a tooltip in the textbox.

What is the best way to do this?

Thank you!
Svetlina Anati
Telerik team
 answered on 10 Mar 2010
3 answers
452 views
Hello

I've a radgrid in my application. I've specified the bound columns for the rad grid in the aspx page.

Now at the run time i want to add another column and insert it in a specific position in the radgrid. I want to persist it across the postbacks invoked by sorting, filtering etc.

Any insights on this?

Thank you
NLV
Yavor
Telerik team
 answered on 10 Mar 2010
0 answers
98 views
I am trying to build a comments engine for a website and need some insite where I should start?
Keen Speed
Top achievements
Rank 1
 asked on 10 Mar 2010
4 answers
146 views
Hello again, I asked for help with my radgrid programming in this topic here. This time, I have a related issue in this javascript function with the update part of it.

For reference, here's the function:
function KeyPressEnter(sender, args)  
    {  
        var $ = $telerik.$;  
        if (args.get_keyCode() != 13)  
            return;  
       
        var el = Telerik.Web.UI.Grid.GetCurrentElement(args.get_domEvent());  
       
        if (el.tagName.toLowerCase() != 'input' && el.tagName.toLowerCase() != 'textarea') return;  
          
        if (sender.get_masterTableView().get_isItemInserted())  
        {  
            var evt = args.get_domEvent();  
            //if (evt.stopPropagation) evt.stopPropagation();  
            if (evt.preventDefault) evt.preventDefault();  
            sender.get_masterTableView().insertItem();  
       
            return false;  
        }  
        var detailtables = sender.get_detailTables();  
          
        if (detailtables.length > 0) {  
            for (var i = 0; i < detailtables.length; i++){   
                if (detailtables[i].get_isItemInserted()) {  
                    var evt = args.get_domEvent();  
                    if (evt.preventDefault) evt.preventDefault();   
                    detailtables[i].insertItem();   
                      
                    return false;   
                }   
            }     
        }  
           
        if ($(el).parents("tr").attr("id") && $(el).parents("tr").attr("id") != "")  
        {  
            var evt = args.get_domEvent();  
            //if (evt.stopPropagation) evt.stopPropagation();  
            if (evt.preventDefault) evt.preventDefault();  
            sender.get_masterTableView().updateItem($(el).parents("tr")[0]);  
       
            return false;  
        }  
    }  
The part of code that updates items is made bold.

While this code in normal situation just works fine and updates my rows when pressing enter, I found a specific situation where it wouldn't work. In one detailview of my radgrid, I put some of the columns of that detailview in read only mode(in the item created event of the radgrid), so that users can only edit the specific fields of a row. It's in this detailview that the javascript generates and error when trying to use this update function. It will generate the error "object expected"  on this line:
if ($(el).parents("tr").attr("id") && $(el).parents("tr").attr("id") != "") 
Further investigation reveals that it's this part: $(el) that generates the error.

After this, I tried playing around with putting columns in read only mode and using this function. I discovered that specifically, if the -first- column of a row is in read only mode when trying to use this code, it will generate an error. With any other column of that row in readonly mode it would work just fine, it's just that first column that generates the "object expected" error.

Do you have any idea how I could fix this issue without putting the first column of my detailview in edit mode?


Thijs van Gestel
Top achievements
Rank 1
 answered on 10 Mar 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?