Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
83 views
Not sure where this one goes...

I have a grid of companies that allows updates to the address of the company.  At the end of that update, I need to ask the user if they want to update the contacts associated with that company to the same address.

Here the code that calls the javascript function:
        ClientScript.RegisterStartupScript(Me.GetType(), "ConfirmMessageBox", "confirmAddressChange(); ", True)

        If hfAddressChange.Value <> String.Empty Then
            Dim x As String = "Do Something here"

        End If

And here is the javascipt it is calling:
        function confirmAddressChange()
        {
             var res = (confirm('"Update Contact Addresses to Match?"')==true);
             document.forms[0].hfAddressChange.valueOf = res;    
             
        }

Basically all I'm doing is getting the response from the user and putting it into a HiddenField on the form.

Everything SEEMS to be working fine, except that the IF statement that checks the HiddenField runs before the confirmation box is run.

How do I call the function and make sure it is run BEFORE I check for the value returned in the HiddenField?

Any suggestions would be GREATLY appreciated.

Thanks.
Andrey
Telerik team
 answered on 22 Nov 2012
1 answer
102 views
I just see your demo as below:
http://demos.telerik.com/aspnet-ajax/orgchart/examples/applicationscenarios/addeditremoveemployees/defaultcs.aspx 

I also have a similar application to draw the structure: There are four nodes as sequence. My requirement is that the first and last node will not have the context menu and the second and third node will have the context menu. How to implement it?

Peter Filipov
Telerik team
 answered on 22 Nov 2012
3 answers
77 views
Hi,

I recently updated to the new version of Asp.Net AJAX RadControls (2012.3.1016.40).
The behaviour of the RadInput controls have changed. When I hoover over a RadTextBox or a RadNumericTextBox the height and width gets one or two pixels larger. See attached image.
Why is this and how can I repair this?

Paul
Vasil
Telerik team
 answered on 22 Nov 2012
10 answers
188 views
Hello,

I want the demo for Filtering and grouping in one radgrid
Please give me the demo for My requirement.

Please help me its urgent.

Regards
Eyup
Telerik team
 answered on 22 Nov 2012
1 answer
141 views
Hello

I am developing a usercontrol using Radgrid. My problem is that when I insert a template column containing a RadAutoCompleteBox the insert command stops firing and the callback from the RadAutoCompleteBox inside the TemplateColumn is invalid. In Edit Mode everything works fine. If I remove the column from the grid the insert command starts firing again and works perfectly, any ideas as to what the problem might be? 

the code for my custom column is as follows:

public class GridLookupColumn : GridTemplateColumn
    {
        private string _lookupDataMember;
 
        public string LookupDataMember
        {
            get { return _lookupDataMember; }
            set { _lookupDataMember = value; }
        }
        private string _lookupTextField;
 
        public string LookupTextField
        {
            get { return _lookupTextField; }
            set { _lookupTextField = value; }
        }
        private string _lookupValueField;
 
        public string LookupValueField
        {
            get { return _lookupValueField; }
            set { _lookupValueField = value; }
        }
        public class LookupActionTemplate : IBindableTemplate
        {
            public GridLookupColumn Column = null;
            
            
            public void InstantiateIn(Control container)
            {
                RadAutoCompleteBox lookup = new RadAutoCompleteBox();
                lookup.ID ="LC" + this.Column.UniqueName;
                lookup.DataSource = Column.Owner.OwnerGrid.DataSource;
                lookup.DataMember = Column.LookupDataMember;
                lookup.DataTextField = Column.LookupTextField;
                lookup.DataValueField = Column.LookupValueField;
                lookup.EnableViewState = true;
                container.Controls.Add(lookup);
                 
                 
                lookup.DataBind();
                lookup.DataBinding += new EventHandler(LookupDataBindingHandler);
                lookup.EntryAdded += new AutoCompleteEntryEventHandler(EntryAddedHandler);
                 
            }
            private void EntryAddedHandler(object sender, EventArgs e)
            {
                RadAutoCompleteBox lookup = sender as RadAutoCompleteBox;
                if (lookup.Entries.Count > 1)
                {
                    lookup.Entries.RemoveAt(0);
                    ExtractValues(lookup.NamingContainer as GridDataItem);
                     
                }
            }
            private void LookupDataBindingHandler(object sender, EventArgs e)
            {
                RadAutoCompleteBox lookup = sender as RadAutoCompleteBox;
                GridDataItem item = (GridDataItem)lookup.NamingContainer;
                string id = DataBinder.Eval(item.DataItem, this.Column.DataField).ToString();
                string text = String.Empty;
                DataSet data = (DataSet)Column.Owner.DataSource;
                foreach (DataRow r in data.Tables[Column.LookupDataMember].Rows)
                {
                    if (r[Column.LookupValueField].ToString() == id)
                    {
                        text = r[Column.LookupTextField].ToString();
                    }
                }
                AutoCompleteBoxEntry entry = new AutoCompleteBoxEntry(text, id);
                if(text != String.Empty)
                lookup.Entries.Add(entry);
                 
                             
                 
            }
 
            public System.Collections.Specialized.IOrderedDictionary ExtractValues(Control container)
            {
                IOrderedDictionary values = new OrderedDictionary();
                RadAutoCompleteBox lookup = container.FindControl("LC" + Column.UniqueName) as RadAutoCompleteBox;
                values.Add(Column.UniqueName, lookup.Entries[0].Value);
                return values;
            }
        }
        public class LookupTemplate : ITemplate
        {
            public GridLookupColumn Column = null;
            public void InstantiateIn(Control container)
            {
                Label l = new Label();
                l.ID = Column.UniqueName;
                container.Controls.Add(l);
                l.DataBinding += new EventHandler(LookupDataBindingHandler);
            }
            private void LookupDataBindingHandler(object sender, EventArgs e)
            {
                Label l = sender as Label;
                GridDataItem item = (GridDataItem)l.NamingContainer;
                string id = DataBinder.Eval(item.DataItem, this.Column.DataField).ToString();
                DataSet data = (DataSet) Column.Owner.DataSource;
                foreach (DataRow r in data.Tables[Column.LookupDataMember].Rows)
                {
                    if (r[Column.LookupValueField].ToString() == id)
                    {
                        l.Text = r[Column.LookupTextField].ToString();
                    }
                }
                  
 
            }
        }
         
        public GridLookupColumn()
        {
             
            LookupActionTemplate lookupActionTemplate = new LookupActionTemplate();
            LookupTemplate lookupTemplate = new LookupTemplate();
            lookupTemplate.Column = this;
            lookupActionTemplate.Column = this;
            this.EditItemTemplate = lookupActionTemplate;
            this.ItemTemplate = lookupTemplate;
            this.InsertItemTemplate = lookupActionTemplate;
            
             
             
             
        }
    }

I create the grid on Page Load as described in the documentation.

Any help is highly appreciated

Best Regards,

Claus Veirup
Antonio Stoilkov
Telerik team
 answered on 22 Nov 2012
2 answers
78 views

Hello, I have some problems with the RadNumericTextBox.
If is set the value

 

var tbox = document.getElementById(elementId);
if (tbox) {
    tbox.value = value;
}

The textbox display value is changed but if i click the textbox the value dissapears.
So i tried to see if the online examples work, but that won't work either. Or i am missing the point.
Ive updated to the latest release of the asp.net ajax controls.

Can you help me?

Greetings
Marcel de Groot



ABECON Groep BV
Top achievements
Rank 1
 answered on 22 Nov 2012
1 answer
106 views
Hello Team ,

I am really happy use telerik controls . There are really good. I am facing one problem , I dont know why it is ? I need you people help .

I am using telerik tab strip , worked for me great for some days . This is my sample code.

 <telerik:radtabstrip id="radGallaryTabStrip" runat="server" skin="Vista" multipageid="radPhotoGallarymultiPage"
                selectedindex="0">
                        <Tabs>
                            <telerik:RadTab Text="Gallery" runat="server">
                            </telerik:RadTab>
                            <telerik:RadTab Text="Floor plans" runat="server" Selected="True">
                            </telerik:RadTab>
                        </Tabs>
                    </telerik:radtabstrip>
            <div class="AP-telericblock">
                <telerik:radmultipage runat="server" id="radPhotoGallarymultiPage" selectedindex="0">
                            <telerik:RadPageView runat="server" ID="radPhotoGallary">
                                <Smart:newPropertyImageGallary ID="ucNewPropertyGallary" runat="server" />
                            </telerik:RadPageView>
                            <telerik:RadPageView ID="radFloorGallary" runat="server">
                               <Smart:newFloorplanGallary ID="ucFloorPlanGallary" runat="server"></Smart:newFloorplanGallary>
                            </telerik:RadPageView>
                           
                        </telerik:radmultipage>
            </div>


After some tabs , my tab clicks are not working . I am attaching a screen shot for you . There is # symbol coming up in the url and controls are not firing . Please help to get out of the problem . It is really urgent for me .

Thanks

Rama. M





Rama
Top achievements
Rank 1
 answered on 22 Nov 2012
1 answer
55 views
Are there any plans for adding caching to the AutocompleteBox like the RadComboBox has?
Kalina
Telerik team
 answered on 22 Nov 2012
3 answers
93 views
This is my requirement,

I have a radgrid - that shows project names
I have a detailed table - that shows project details

So by default i want to expand all the projects and bind the project details to detailed table. The DataSource value for detailed table will be from SQL. 

Please give me a link for similar sample. Or tell me some idea. 

Right now, i tried to expand the node by default in prerender method. But the detailed table's datasource is coming from the Grid i.e. the project names is displayed in detailed table also. 

Any Suggestion?
Shinu
Top achievements
Rank 2
 answered on 22 Nov 2012
20 answers
3.0K+ views
Hi,

Trying to add a RadAjaxManager to my page.  I'm getting the "Error Creating Control ... Could not load file or assembly 'Telerik ... " error.

I'm using VS 2005 Orcas and the v3.5 .NET framework ... I'm also using Vista x64 Enterprise ... and I also have the Microsoft AJAX Dev Toolkit installed.  I've also installed the SP1 for Prometheus 

BTW ... the RadAjaxmanager for RAD 2007 Q1 SP1 works fine ...

Cheers,

Gp.
Matthew
Top achievements
Rank 1
 answered on 21 Nov 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?