Telerik Forums
UI for WinForms Forum
1 answer
1.4K+ views
Hi there

I'm trying to achieve row-level validation and saving. The validation is working OK and and I can reject invalid user-input at the row level.

However I'm a bit lost as to how which event to use to catch the fact a row has changed so I can then call dataset.savechanges().

I've tried -
RowsChanged event but it fires when the grid is first populated with data
RowValidated event but it fires AFTER I leave the row that was updated
RowValidating event which is nearly there but it isn't until it's finished that I can detect changes in my dataset using datatable.getchanges()

The basic point is that i'd like remove the need for a Save button that will save ALL changes to the data in the grid. The reason for this is that the database has lots of users and I want to maintain concurrency. If I can get the database record to change when a ROW is updated then there is less chance of concurrency issues.

Thanks in advance



Richard Slade
Top achievements
Rank 2
 answered on 12 Apr 2011
1 answer
198 views
I have problem making array of telerik controls or converting or casting them to Windows forms controls, can anyone help?

when I try to search telerik control in control collection,like this


private
void LoopControls(Control.ControlCollection controls)

{

 

   foreach (Control control in controls)

 

    {

        if (control is RadButtonElement)

        {

        }

    }

 }

 

system generates following execption

 

 

Cannot convert type System.Windows.Forms.Control to Telerik.WinControls.UI.RadButtonElement
Richard Slade
Top achievements
Rank 2
 answered on 12 Apr 2011
2 answers
508 views
Hi
i am using telerik q3 2010 treeview for winforms

in my project i select multiple nodes in the treeview and user can select different nodes depending on his choice but it seems that the old selected nodes is not clearing and keep saving the old selected nodes
i used :
radtreeview.selectednodes.clear()
but it seems it is not clearing the selected nodes is there any code that could be used to clear selected nodes
any help is appreciated
regards,
jack abdallah
Top achievements
Rank 1
 answered on 11 Apr 2011
12 answers
255 views
Hi,

I am getting an error throw when I try to add the column names to the child and parent relations in a hierarchical gridview.  I am using your WINForms sample, except that I changed the datasource to Entity Framework 4 .edmx, and am using .Net 4.0 on a WIN7 OS.  I've attached 2 files, 'Form1' shows the results.  All works fine, except the child grids are not linked to the ContactID on the grid (the relationships are defines properly in the .edmx).  'Relations' shows the results I'm getting when I try to set them in the properties window.

Thanks

Steve
Pavel Pavlov
Telerik team
 answered on 11 Apr 2011
3 answers
177 views

Hello

Can anybody tell me how I can detect where the context menu is clicked, in particular I'm looking to detect a right click in the blank space below rows (see attached file.)

The following snippet stops the right clicking on the header, and allows right clicking on a row, but I can't seem to find out when the "whitespace" is clicked? - Any clues?

Many thanks

Terry

Private Sub RadGridView1_ContextMenuOpening(ByVal sender As Object, ByVal e As Telerik.WinControls.UI.ContextMenuOpeningEventArgs) Handles RadGridView1.ContextMenuOpening
  
          
        Dim i As Integer = 0
        Do While i < e.ContextMenu.Items.Count
            e.ContextMenu.Items.Clear()
            i += 1
        Loop
  
        If TypeOf e.ContextMenuProvider Is GridHeaderCellElement Then Exit Sub
  
          
        Dim customMenuItem1 As RadMenuItem = New RadMenuItem()
        Dim customMenuItem2 As RadMenuItem = New RadMenuItem()
        Dim customMenuItem3 As RadMenuItem = New RadMenuItem()
  
        customMenuItem1.Text = "Insert Company History"
        customMenuItem2.Text = "Remove Company History"
        customMenuItem3.Text = "Add/Edit Roles..."
  
          
            Dim separator As RadMenuSeparatorItem = New RadMenuSeparatorItem()
            e.ContextMenu.Items.Add(customMenuItem1)
            AddHandler e.ContextMenu.Items(0).Click, AddressOf RowInsert
            e.ContextMenu.Items.Add(customMenuItem2)
            AddHandler e.ContextMenu.Items(1).Click, AddressOf RowDelete
            e.ContextMenu.Items.Add(separator)
            e.ContextMenu.Items.Add(customMenuItem3)
  
        If RadGridView1.RowCount = 0 Then
            e.ContextMenu.Items(0).Visibility = ElementVisibility.Visible
            e.ContextMenu.Items(1).Visibility = ElementVisibility.Hidden
            e.ContextMenu.Items(2).Visibility = ElementVisibility.Hidden
        End If
  
    End Sub
Richard Slade
Top achievements
Rank 2
 answered on 11 Apr 2011
1 answer
207 views
Hi,

I want to add the some Combobox,TextBox and Button on the DockTabStrip or Top of the ToolWindow of RadDock Control.
But i am not getting any way to do this.

And my anathor problem is that i rounded the shape of the e.DockWIndow with FIllPrimitive and BorderPrimitive properties that rounded
the upper portion of the ToolWindow but back portion of the control is looking odd/rectangle.

The Snap Shot of my problem with code over it is attached with this thread (dock.png).

Please review this problem as soon as possible.

 
private void radDock1_DockStateChanged_1(object sender, DockWindowEventArgs e)
        {
            try
            {
                e.DockWindow.Text = strCaption;
                FillPrimitive fill = (FillPrimitive)((ToolTabStrip)e.DockWindow.DockTabStrip).CaptionElement.Children[0];
                BorderPrimitive border = (BorderPrimitive)((ToolTabStrip)e.DockWindow.DockTabStrip).CaptionElement.Children[1];
                fill.AutoSize = false;
 
                fill.Size = new Size(e.DockWindow.Width, 35);
                
               border.Shape = this.toproundedshape;
                
            }
            catch (Exception)
            {
                throw;
            }
        }
Alexander
Telerik team
 answered on 11 Apr 2011
3 answers
89 views
Hi,

There is any way to add user controls or controls on the e.DockWindow.DockTabStrip or at tilebar of tool window.
Alexander
Telerik team
 answered on 11 Apr 2011
12 answers
198 views

Hello,

I have recently upgraded to "RadControls for WinForms Q2 2010 SP2" and since then, occasionally, I'm getting this exception:

AvlEnumerator:version mismatch

The relevant call stack is:

 at Telerik.Collections.Generic.AvlTree`1.Enumerator.CheckVersion()
 at Telerik.Collections.Generic.AvlTree`1.Enumerator.MoveNext()

What can be the problem? I couldn’t find documentation for it.

Thanks,

sco
Top achievements
Rank 1
 answered on 09 Apr 2011
2 answers
130 views
I've followed this tutorial for binding hierarchy data:

http://www.telerik.com/help/winforms/gridview-hierarchical-grid-tutorial-binding-to-hierarchical-data.html

The data is displaying properly, and the Parent level template works as it should. However, the child level template is not working at all. Whether I use the grid property builder or the template collections interface, I can not customize which columns are visible or change header names etc. It always shows every single column from the table adapter. I need to be able to use foreign keys which are invisible, not to mention renaming headers or resizing columns.

Thanks for the help.
Ryan
Top achievements
Rank 1
 answered on 08 Apr 2011
1 answer
97 views
Hi,
in my winforms application there is one form with many tabbed documents. At the moment I see only the first 3 or 4 tabbed documents. How I can reach any tabbed document at design time to customize the content?
Kind regards.
Christian
Stefan
Telerik team
 answered on 08 Apr 2011
Narrow your results
Selected tags
Tags
GridView
General Discussions
Scheduler and Reminder
Treeview
Dock
RibbonBar
Themes and Visual Style Builder
ChartView
Calendar, DateTimePicker, TimePicker and Clock
DropDownList
Buttons, RadioButton, CheckBox, etc
ListView
ComboBox and ListBox (obsolete as of Q2 2010)
Form
Chart (obsolete as of Q1 2013)
PageView
MultiColumn ComboBox
TextBox
RichTextEditor
PropertyGrid
Menu
RichTextBox (obsolete as of Q3 2014 SP1)
Panelbar (obsolete as of Q2 2010)
PivotGrid and PivotFieldList
Tabstrip (obsolete as of Q2 2010)
MaskedEditBox
CommandBar
PdfViewer and PdfViewerNavigator
ListControl
Carousel
GanttView
Diagram, DiagramRibbonBar, DiagramToolBox
Panorama
New Product Suggestions
Toolstrip (obsolete as of Q3 2010)
VirtualGrid
AutoCompleteBox
Label
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
Documentation
SplitContainer
Map
DesktopAlert
CheckedDropDownList
ProgressBar
TrackBar
MessageBox
Rotator
SpinEditor
CheckedListBox
StatusStrip
LayoutControl
SyntaxEditor
Wizard
ShapedForm
TextBoxControl
CollapsiblePanel
Conversational UI, Chat
DateTimePicker
TabbedForm
CAB Enabling Kit
GroupBox
WaitingBar
DataEntry
ScrollablePanel
ScrollBar
ImageEditor
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
FileDialogs
ColorDialog
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
BindingNavigator
Styling
Barcode
PopupEditor
RibbonForm
TaskBoard
Callout
NavigationView
ColorBox
PictureBox
FilterView
Accessibility
Licensing
VirtualKeyboard
DataLayout
ToastNotificationManager
ValidationProvider
CalculatorDropDown
Localization
TimePicker
BreadCrumb
ButtonTextBox
FontDropDownList
BarcodeView
Security
LocalizationProvider
Dictionary
SplashScreen
Overlay
Flyout
Separator
SparkLine
TreeMap
StepProgressBar
ToolbarForm
NotifyIcon
DateOnlyPicker
AI Coding Assistant
Rating
TimeSpanPicker
Calculator
OfficeNavigationBar
TaskbarButton
HeatMap
SlideView
PipsPager
AIPrompt
TaskDialog
TimeOnlyPicker
+? more
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?