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

I'm using RadGrid with an ObjectDataSource and SQL Server. All works well. However, I would like to have more control over when the changes to the data are sent (updated) to the database. That is, I would like to allow the user to make changes in multiple rows of the grid, and then save them when he presses a "Save" button or discard them by pressing a "Cancel" button.

I set AllowAutomaticUpdates to false, but then the user's changes to the data are lost when he presses "Update."

I've done my due diligence with the documentation, forums and such, but can't find the solution.

Thanks.

Veli
Telerik team
 answered on 30 Jun 2009
1 answer
129 views
Hi,
I have a GridDropDownColumn which is bound to a datafield.
The column works very well - shows the right text for the corresponding values.

Problem is when the datafield holds a value which does not exist in the DropDown DataSource the Column always displays the first value in the DataSource.
My wish is to display a blank value (not text) when there is no matching Value in the dataSource.

Is there an easy way to do that (I mean without catching the ItemDataBound event and manually checking each value against the dataSource).

Thanks,
Revital
Veli
Telerik team
 answered on 30 Jun 2009
1 answer
129 views
I have a grid in my web site with a GridTemplateColumn inside and I am using <ItemTemplate> to layout a custom appearance.
Here's the ItemTemplate contents :

<asp:Image ID="Image1" Style="float: left;" Width="171px" Height="167px"   
                                    ImageUrl='<%# "ImageFromDB.ashx?ID=" + Eval("KeyID") %>' runat="server"   
                                    AlternativeText="Stock Image" />  
                                <div>  
                                    <span style="font-weight: bold; font-family: Arial Black;">Description:</span>  
                                    <%# Eval("Description") %>  
                                    <br />  
                                    <br />  
                                    <span style="font-weight: bold;">Manufacturer:</span>  
                                    <%# Eval("Manufacturer") %>  
                                    <br />  
                                    <br />  
                                    <span style="font-weight: bold;">Code:</span>  
                                    <%# Eval("Code") %>  
                                </div> 

I want to enter two dynamically created divs to the left of the template that will appear vertically with a Field Description inside.
How can I do that?
Thank you very much!
Dimo
Telerik team
 answered on 30 Jun 2009
1 answer
159 views
I have a base page (Default.aspx) and two pop-up windows (PopUp1.aspx and PopUp2.aspx). When I click a button in Default.aspx I bring the PopUp1.aspx as a modal window. For some purpose I need to open another PopUp window (PopUp2.aspx) from the PopUp1.aspx as the second pop-up window.

And when I close each of these windows I need to perform some server side actions.So I have OnClientClose event in my Window manager. All required JavaScript codes are called from a file named Default.js and every aspx file has a referance to it.

To visualize the example please refer to the shape below:
http://www.freeimagehosting.net/uploads/c8747568ca.jpg

Everything runs OK until I close the second poup and try to call raise a request to the ajax panel in the first popup. I mean
ajaxManager = $find('ajaxPanelMain'); 
ajaxManager.ajaxRequest('UpdateMain'); 
code works fine but
ajaxManager = $find('ajaxPanelPopUp1'); 
ajaxManager.ajaxRequest('UpdatePopUp'); 

crashes because it can not find the Ajax Panel "ajaxPanelPopUp1" which is in the PopUp1.aspx. IT seems that this code can only see the Ajax Panel at the main page "Default.aspx". How can I call the Ajax Panel in the first pop-up window PopUp1.aspx?

Regards & Thanks in advance.





Veli
Telerik team
 answered on 30 Jun 2009
1 answer
102 views
Hi

I have countered a problem using your radgrid, ajax and webusercontrol on insert

Im trying to create a new record using the built in "add new record" from CommandItemDisplay="Top". A webusercontrol shows up a everything is fine.

But:
In my usercontrol i have a textbox where I have a OnTextChanged event which sets up some settings for the user.
Now when i hit the tab-button the event fires correctly but after that my usercontrol GUI is locked. That is when i try to click on any other textbox inside my usercontrol is gets the "focus" or "pipe blinking" but i cant enter any text.

If I mark anything outside the usercontrol or have a button in the usercontrol that gets the focus it allows me to use the textboxes again.

I've trying running the usercontrol in another .aspx without it beeing used in a radgrid and that works fine. It is also working in the grid when im not using any Ajax.

This is how I use the Ajax:
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">  
            <AjaxSettings> 
                <telerik:AjaxSetting AjaxControlID="radGRegisterTime">  
                    <UpdatedControls> 
                        <telerik:AjaxUpdatedControl ControlID="radGRegisterTime" LoadingPanelID="RadAjaxLoadingPanel1" /> 
                    </UpdatedControls> 
                </telerik:AjaxSetting> 
            </AjaxSettings> 
            <AjaxSettings> 
                <telerik:AjaxSetting AjaxControlID="radGRegisterTimeSecondaryTasks">  
                    <UpdatedControls> 
                        <telerik:AjaxUpdatedControl ControlID="radGRegisterTimeSecondaryTasks" LoadingPanelID="RadAjaxLoadingPanel1" /> 
                    </UpdatedControls> 
                </telerik:AjaxSetting> 
            </AjaxSettings> 
        </telerik:RadAjaxManager> 
        <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="75px" Width="75px" Transparency="10">  
           <img alt="Loading..." src='<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>' style="border:0;" /> 
   
        </telerik:RadAjaxLoadingPanel> 

The problem also occurs when using ms updatepanel.
 
So im thinking if there could be some threading that kinda lock the control.

Hope you see my problem.

Thanks in advance
Veli
Telerik team
 answered on 30 Jun 2009
5 answers
127 views
Have noticed a couple of bugs whilst developing a wrapper for your Window controls.

I think it would help you to know that with my wrapper, every window gets spawned from window.top where there is an instance of RadWindowManager exposed.  This is to prevent dialogs opening inside each other.

Bug 1:
When multiple modal windows are open (non-modal can be open too) and I call the cascade() function, the modal windows become non-modal.

Bug 2:
To see this bug you need to do the following...
- Open a Modal Dialog that has a link inside that will spawn another modal dialog (from window.top).
- Ok, so we've got a dialog open - now click the link to spawn the second dialog and then quickly right click in some whitespace of the first dialog, before the second one has appeared.   Wait for dialog 2 to render and load. Your browsers context menu should still be visible.  If you then click on Refresh (IE), or This Frame > Reload (FF) the first dialog will reload and re-render itself on-top of dialog 2!

I am personally not overly bothered about bug 2, but bug one is a little annoying, as I want our clients to have an always-on-top global controls panel that contains a Cascade Windows button.

Any help is greatly appreciated!

Georgi Tunev
Telerik team
 answered on 30 Jun 2009
3 answers
157 views
Hi

I am trying to set a view from a multiview as an updated control in rad ajax manager.

This is the aspx

 

<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">

 

 

<AjaxSettings>

 

 

 

<telerik:AjaxSetting AjaxControlID="btnSubmit">

 

 

<UpdatedControls>

 

 

 

<telerik:AjaxUpdatedControl ControlID="vwSuccess" />

 

 

</UpdatedControls>

 

 

</telerik:AjaxSetting>

 

 

</AjaxSettings>

 

 

</telerik:RadAjaxManager>

When the page runs i get this error

 

Controls added to a ViewCollection must be of type View.

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.ArgumentException: Controls added to a ViewCollection must be of type View.

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:

[ArgumentException: Controls added to a ViewCollection must be of type View.]
   System.Web.UI.WebControls.ViewCollection.AddAt(Int32 index, Control v) +92
   Telerik.Web.UI.RadAjaxControl.MoveUpdatePanel(Control initiator, Control updated) +123
   Telerik.Web.UI.RadAjaxControl.PerformRender() +420
   Telerik.Web.UI.RadAjaxControl.OnPageRender(HtmlTextWriter writer, Control page) +1223
   Telerik.Web.UI.RadAjaxControl.RenderPageInAjaxMode(HtmlTextWriter writer, Control page) +87
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +98
   System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +21
   System.Web.UI.Page.Render(HtmlTextWriter writer) +27
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +53
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +310
   System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +24
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +7375


many thanks
Sebastian
Telerik team
 answered on 30 Jun 2009
3 answers
224 views
Hello,

We have tried to bind SPList to the RadGrid using two strategies that we saw in the examples and forum.
1.To use the method SPList.GetDataTable() and to bind the dataTable to the RadGrid. The problem with this option that GetDataTable() contains only String and Int32 types, no Boolean and other types of SPField.
2. The second strategy was to bind SPListItemCollection of the list (we tryed to return spesific columns and all items).
The problem here is RadGrid does not display all columns that are in SPListItemCollection, particulary it does not display the columns that were added manually from sharepoint UI. We work on server side, we also tried autogenerate columns and custom generate, in both cases there is no results in RadGrid.

Can you please sent us some example of how to bind SPListItemCollection to RadGrid or any other way to bind SPList to RadGrid.

Thank you,
Shiri.
Bruno
Top achievements
Rank 2
 answered on 30 Jun 2009
3 answers
171 views
HI,

I am using Rad Editor Control. Let me tell you what I need to know.

When I drag and Drop image from any IE browser to Editor and when I release the mouse, I need to replace that HTML image tag (generated on html side) with my scripts.

So As soon as I release the mouse, I need some event handler so I can write the code and replace that HTML image tag with my small script.

For this task which event I can use of Rad Editor to fulfill my requirement.

Thnaks
Dipsa Shah
Rumen
Telerik team
 answered on 30 Jun 2009
2 answers
84 views
I want all RadGrids on my site to have fixed sized columns and that text should wrap to a new line if a word or sentence is to long. Which style should I use?
Anders
Top achievements
Rank 1
 answered on 30 Jun 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?