Telerik Forums
UI for WinForms Forum
1 answer
114 views
We have a WinForms application with WPF Controls embedded in it and various WPF applications. All applications use Telerik controls. I am looking into re-theming them. I can't find any information to easily compare themes. I've seen that there is an Office2019 theme in both WinForms and WPF. Are there any comparisons of them anywhere? Are there any combinations of WinForms and WPF themes that go well together without much alteration?
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 04 Apr 2022
1 answer
83 views
The Enter event of the RadCheckedDropDownList is not firing. I have MessageBox.Show("Hello"); in the body of the event and not shows up.
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 01 Apr 2022
2 answers
83 views

Buonasera 

devo realizzare un pannello, contenete testo e immagini, scollabile in modo touch , cioè senza barra laterale,  attivando lo scoll con il mouse

"su e giu", sto provando con  scollablepanel  ma non so come attivare gli eventi scoll . 

e possibile avere una diritta ? magari c'e' un esempio in vb.net  ?

grazie

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 01 Apr 2022
1 answer
112 views

I am new at Telerik.

I would like to validate data that are in my radgridview,. If data are saved in the database they must be highlighted orange. The radgriview in my form does not have any columns before I run the application. The columns are developed programmatically and the radgridview bound at runtime.

 

How can I validate the columns?

I have tried the following code but it does not work.

 

Can you tell me what I am doing wrong?

 

Thank you in advance

 void RadGridView_CellValidating(object sender, Telerik.WinControls.UI.CellValidatingEventArgs e)
        { 
             var column = e.Column as GridViewDataColumn;

            if (e.Row is GridViewDataRowInfo && column != null && column.Name == "Name")
            {
                var Value = (string)e.Value;
                var Row = (GridViewDataRowInfo)e.Row;
                if (string.IsNullOrEmpty((string)e.Value) || ((string)e.Value).Trim() == string.Empty)
                {
                    e.Cancel = true;
                    ((GridViewDataRowInfo)e.Row).ErrorText = "Validation error!";
                }
                else
                {
                    ((GridViewDataRowInfo)e.Row).ErrorText = string.Empty;
                }
            }
            }
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 01 Apr 2022
1 answer
168 views

 

Hello,

I have an unbound hierarchical radgridview that has a parent template and two child templates. The master templates work fine, I can insert, type or paste data. But in the child template, I cannot add any data or rows. It remains blank. Can you tell me what I am doing wrong?

My code are below.

Thank you in advance.

 

private void TestForm_Load(object sender, EventArgs e)
        {            
         // Setup the Master Template
                RadGrid.MasterTemplate.Columns.Add          (new GridViewTextBoxColumn("Name"));
                RadGrid.MasterTemplate.Columns.Add          (new GridViewTextBoxColumn("Description"));
                RadGrid.MasterTemplate.Columns.Add          (new GridViewDateTimeColumn("Date"));
                RadGrid.MasterTemplate.Columns.Add          (new GridViewDecimalColumn ("Value"));
                RadGrid.MasterTemplate.Columns.Add          (new GridViewTextBoxColumn("Status"));
                RadGrid.MasterTemplate.Columns.Add          (new GridViewTextBoxColumn("NameCode"));
                RadGrid.MasterTemplate.Columns.Add          (new GridViewTextBoxColumn("Event"));

                RadGrid.AllowAddNewRow                              = true;
                RadGrid.AutoGenerateHierarchy                     = true;
                RadGrid.AutoSizeColumnsMode                      = GridViewAutoSizeColumnsMode.Fill;

                //Setup Child Template
                GridViewTemplate Childtemplate                       = new GridViewTemplate();
                RadGrid.MasterTemplate.Templates.Add         (Childtemplate );
                Childtemplate.AllowAddNewRow                         = true;
                Childtemplate.AutoSizeColumnsMode                 = GridViewAutoSizeColumnsMode.Fill;

                Childtemplate.Columns.Add                                (new GridViewTextBoxColumn  ("Name"));
                Childtemplate.Columns.Add                               (new GridViewTextBoxColumn  ("Description"));


                //Relation between Parent & child
                GridViewRelation relation                            = new GridViewRelation(RadGrid.MasterTemplate);
                relation.ParentTemplate                              = RadGrid.MasterTemplate;
                relation.ChildTemplate                               = Childtemplate;

                relation.ParentColumnNames.Add("Name");
                relation.ParentColumnNames.Add("Description");
                relation.ParentColumnNames.Add("PtDate");
                relation.ParentColumnNames.Add("Value");
                relation.ParentColumnNames.Add("Status");
                relation.ParentColumnNames.Add("NameCode");
                relation.ParentColumnNames.Add("Event");

                relation.ChildColumnNames.Add ("Name");
                relation.ChildColumnNames.Add ("Description");


                RadGrid.Relations.Add(relation);

 //load data
                LoadUnboundData();

        }

private void LoadUnboundData()
{
 
                using (RadGrid.DeferRefresh())
                    {
                     TestDataSet Processes                              = new TestDataSet();
                
                    using ( RadGrid.DeferRefresh())
                    {
                     GridViewTemplate firstLevelTemplate                        =  RadGrid.MasterTemplate.Templates[0];
 
                        for (int i = 0; i < Processes.AllProcesses.Count; i++)
                        {
                    
                        TestDataSet.AllProcessesRow ProcessRow         = Processes.AllProcesses[i];
                       
                         RadGrid.MasterTemplate.Rows.Add(
                             ProcessRow.Name,
                             ProcessRow .Description, 
                             ProcessRow.Date, 
                             ProcessRow .Value,
                             ProcessRow .Status, 
                             ProcessRow .NameCode,
                             ProcessRow .Event
                                );
                        
                        for (int j = 0; j < Processes.ProcessTasks.Count; j++)
                        {
                         TestDataSet.ProcessTasksRow TasksRow     = Processes.ProcessTasks[j];
                     
                         firstLevelTemplate.Rows.Add(
                             TasksRow.Name,
                             TasksRow.Description
                                );
                        }
                        }                                  
                    }
                }
        }

 

                                                    
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 01 Apr 2022
1 answer
90 views

We would like to draw a red border around the camera stream while video is recording. I tried attaching ot the StartRecording event and modifying the UI internals:

 ((Telerik.WinControls.UI.RadWebCamElement)(radWebCam1.GetChildAt(1))).DrawBorder = true;
 ((Telerik.WinControls.UI.LightVisualElement)(radWebCam1.GetChildAt(2))).BorderBoxStyle = Telerik.WinControls.BorderBoxStyle.SingleBorder;
 ((Telerik.WinControls.UI.LightVisualElement)(radWebCam1.GetChildAt(2))).BorderWidth = 8F;
 ((Telerik.WinControls.UI.LightVisualElement)(radWebCam1.GetChildAt(2))).BorderColor = System.Drawing.Color.Red;

 

and it sortof works.. the border reduces size, and isn;t shown at the bottom. I have the 

 radWebCam1.ControlPanelHeight = 0;

because we are adding custom controls.  but when we StopRecording and I execute

((Telerik.WinControls.UI.RadWebCamElement)(radWebCam1.GetChildAt(1))).DrawBorder = false;

the border is not hidden.

The camera control is docked on teh form next to a collapsible panel, If I expand the panel, the border goes to full size.  But it still doesn't hide when I set DraBorder to false.

 

 

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 31 Mar 2022
1 answer
68 views

I would like to set columns in the Gridview as unique name. The Gridview is in unbound mode.

How can I proceed?

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 31 Mar 2022
1 answer
132 views

WinForms v 2020.1.218.40

 

Editing an decimal element in a RadPropertyGrid causes the data to be rounded to 2 decimal places.

pre-edit:

editing:

post edit (no user made changes):

 

The desired behavior is to preserve at least original precision.

Setting the DecimalPlaces property on the BaseSpinEditorElement in the EditorInitialized event handler to 12 as suggested here: https://www.telerik.com/forums/propertygrid-rounding

caused this behavior when editing:

and post-edit (no user input):

Suggestions?

 

 

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 31 Mar 2022
1 answer
59 views

Hello,

I am developing a hierarchical radgridview using winform. I am able to retrieve data from the database (bound data). I would like to enable users to add multiple rows in the same radgridview and then save everything to the database. I have developed another radgridview that allows users to enter data. but I want to perform these functionalities into one radgridview.

When I am trying to do that, the system says: " Rows cannot be programmatically added to the datagridview's row collection when the control is data-bound".

Can you help me with this please?

 

Thank you

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 30 Mar 2022
1 answer
83 views

I have a RadTextBox data bound to an Decimal field (12,9).   When the user hits the "DELETE" button on their keyboard to blank out that field's value, the value is cleared out, but the user cannot exit the control until the user enters a value of some kind (Alpha or Numeric). This is not the desired outcome that we would like.  What I would like to happen is for the bound field's value to be set to null.  Can anyone help me with code sample please.  I have tried also using a MaskedEditBox with a MaskType of  Numeric and Mask of F9, but this also gives us undesired results (0.0000000) when user clicks the DELETE button on their keyboard.

Thank you.Text

Dinko | Tech Support Engineer
Telerik team
 answered on 30 Mar 2022
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
ComboBox and ListBox (obsolete as of Q2 2010)
ListView
Chart (obsolete as of Q1 2013)
Form
PageView
MultiColumn ComboBox
TextBox
RichTextEditor
Menu
PropertyGrid
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
Diagram, DiagramRibbonBar, DiagramToolBox
GanttView
Panorama
New Product Suggestions
Toolstrip (obsolete as of Q3 2010)
VirtualGrid
AutoCompleteBox
Label
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
Documentation
SplitContainer
Map
DesktopAlert
ProgressBar
CheckedDropDownList
Rotator
TrackBar
MessageBox
SpinEditor
StatusStrip
CheckedListBox
Wizard
ShapedForm
SyntaxEditor
TextBoxControl
LayoutControl
CollapsiblePanel
Conversational UI, Chat
DateTimePicker
TabbedForm
CAB Enabling Kit
DataEntry
GroupBox
ScrollablePanel
WaitingBar
ScrollBar
ImageEditor
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
ColorDialog
FileDialogs
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
BindingNavigator
PopupEditor
RibbonForm
Styling
TaskBoard
Barcode
ColorBox
Callout
FilterView
PictureBox
VirtualKeyboard
NavigationView
Accessibility
DataLayout
ToastNotificationManager
ValidationProvider
CalculatorDropDown
Localization
TimePicker
ButtonTextBox
FontDropDownList
Licensing
BreadCrumb
Security
LocalizationProvider
Dictionary
Overlay
Separator
SparkLine
TreeMap
StepProgressBar
SplashScreen
Flyout
ToolbarForm
NotifyIcon
Rating
TimeSpanPicker
BarcodeView
Calculator
OfficeNavigationBar
TaskbarButton
HeatMap
SlideView
PipsPager
AIPrompt
TaskDialog
+? more
Top users last month
Henri
Top achievements
Rank 2
Iron
Iron
Iron
SUNIL
Top achievements
Rank 2
Iron
Iron
Iron
David
Top achievements
Rank 1
Jackson
Top achievements
Rank 1
Iron
Iron
Tim
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Henri
Top achievements
Rank 2
Iron
Iron
Iron
SUNIL
Top achievements
Rank 2
Iron
Iron
Iron
David
Top achievements
Rank 1
Jackson
Top achievements
Rank 1
Iron
Iron
Tim
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?