Telerik Forums
UI for WinForms Forum
2 answers
79 views

This is a follow-up to my question from last week re a data-driven property grid.

1. Is there any way to remove the white space to the left?

2. In the (abbreviated) code below, I am able to set the ForeColor of the text description but If I try the BackColor, nothing happens. Perhaps a bug?

private void propDataDriven_ItemFormatting(object sender, PropertyGridItemFormattingEventArgs e)
{
    PropertyGridItemElement el = e.VisualElement as PropertyGridItemElement;

    el.TextElement.ForeColor = Color.Red; //works fine

    el.TextElement.BackColor = Color.Green; //does nothing
}

 

3. Looking at the date entry, I turned off the context menu but the vertical ellipsis still appears when I click in the cell. Nothing happens when I click on this though. is this intended behavior? I'd rather not see it at all.

Thanks

Carl

Nadya | Tech Support Engineer
Telerik team
 answered on 13 Sep 2023
1 answer
48 views

I'm trying to extend the default capabilities of Telerik's PropertyGrid with some custom editors. However, I'm a little perplexed as to how to get the RadPopupEditor to work.

Looking at the Telerik Theme Viewer tool, there is a rough example of what I'm trying to achieve with the TextAlignment setting (Although I intend to fill the PopupContainer with other components).



Has anyone managed to replicate this and can point me in the right direction?

Thanks!

 
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 14 Aug 2023
1 answer
70 views

Hi, could you tell me how to remove an item from the propertygrid that is highlighted in red? this appears after editing a field

theme: office2019dark

telerik winforms: r1 2023

Dinko | Tech Support Engineer
Telerik team
 answered on 08 Jun 2023
1 answer
53 views

Hi guys,

I have been searching for a correct answer for that, but without success. It looks like work in C# but not in VB.

I want to implement a TAB between the rows in this sample project. Any idea what is missed?

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 18 May 2023
1 answer
61 views

Is there a Winforms example of a RadCheckedDropDownList as an Editor for a PropertyGrid?

There is a sample for WPF, https://docs.telerik.com/devtools/wpf/controls/radpropertygrid/features/radenumeditor

There is sample for Winforms Gridview, https://docs.telerik.com/devtools/winforms/controls/dropdown-listcontrol-and-checkeddropdownlist/checkeddropdownlist/how-to/use-as-radgridview-editor

but nothing for Winforms PropertyGrid.

How would I get the following to appear as a checked drop down editor inside a property grid in winforms?


using CommunityToolkit.Mvvm.ComponentModel;

namespace ProjectXYZ.Model.Enums;

public enum BroadcastPlanEnum
{
    Plan1, Plan2, Plan3, Plan4, Plan5, Plan6
}

public sealed partial class BroadcastPlanActive : ObservableObject
{
    [ObservableProperty]
    private BroadcastPlanEnum broadcastPlan;

    [ObservableProperty]
    private bool selected;
}

 

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

Hello,
I am getting to know the RADPropertyGrid control, it seems flexible.
I have an XML file where "Key" would be the property name and "Value" would be the value in RADPropertyGrid. Where required, I also have a value list between the "ValueList" element. My question is, how can I pass the XML so that the value list for that element is displayed as a string in a combobox in the RADPropertyGrid associated with the property?

Can you show me a sample project on how to do this?

Sample XML:

<PictureBox>
    <Property>
        <Key>EnableClickZoom</Key>
        <Value>False</Value>
    </Property>
    <Property>
        <Key>EnableZoom</Key>
        <Value>False</Value>
    </Property>
    <Property>
        <Key>EnableAutoPan</Key>
        <Value>False</Value>
    </Property>
    <Property>
        <Key>SizeMode</Key>
        <Value>Fit</Value>
        <ValueList>
            <Value>Normal</Value>
            <Value>Stretch</Value>
            <Value>Fit</Value>
        </ValueList>
    </Property>
    <Property>
        <Key>Zoom</Key>
        <Value>30</Value>
    </Property>
    <Property>
        <Key>InterpolationMode</Key>
        <Value>Default</Value>
        <ValueList>
            <Value>Default</Value>
            <Value>Low</Value>
            <Value>High</Value>
            <Value>Bilinear</Value>
            <Value>Bicubic</Value>
            <Value>NearestNeighbor</Value>
            <Value>HighQualityBilinear</Value>
            <Value>HighQualityBicubic</Value>
        </ValueList>
    </Property>
</PictureBox>
Dinko | Tech Support Engineer
Telerik team
 answered on 05 Jul 2022
2 answers
174 views

Hi.

Im tring to design a form like this to display some info. prop3 is a list of N string where N is variable. after i learnt some controls and found that property grid with custom item is accessible. i also read the custom item in property grid and tried, but i didnt get the result i want. 

in my code, i changed enum to list<string>. and item.deliveryType to item.prop3 which type is string.

  

btw, i use managed c++. thanks.

 

F
Top achievements
Rank 1
Iron
 updated answer on 18 May 2022
1 answer
76 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
136 views

I have a PropertyGrid with 2 types of editors ; SpinEditor and DropDownListEditor. After the user changes a value in a SpinEditor, it triggers the event PropertyValueChange. However, after the user selects a new value in the DropDownListEditor, it does not trigger the PropertyValueChange. The ValueChanged event is fired but the new data is not saved in the item at this point. 

How can I make it trigger the PropertyValueChange event after the user changes the value in the DropDownList?

Thanks!

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

Hi~!

I am using RadPropertyGrid in WinForm. 

One item of propertygrid is File Path(string). When user click the File Path element to edit, I want to show Openfiledialog.

When I use Windows default control, it works well, but when I use telerik control, it doesn't work.

{

        string _LogFile = "";

        [Category("Design")]
        [Editor(typeof(FileLocationEditor), typeof(System.Drawing.Design.UITypeEditor))]
        [Description("Viewer background image path.")]
        public string LogFileName
        {
            get
            {
                return _LogFile;
            }
            set
            {
                _LogFile = value;
            }
        }
    }

    public class FileLocationEditor : UITypeEditor
    {
        public override UITypeEditorEditStyle GetEditStyle(ITypeDescriptorContext context)
        {
            return UITypeEditorEditStyle.Modal;
        }

        public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value)
        {
            using (OpenFileDialog ofd = new OpenFileDialog())
            {
                // set file filter info here
                if (ofd.ShowDialog() == DialogResult.OK)
                {
                    return ofd.FileName;
                }
            }
            return value;
        }
    }
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 01 Dec 2021
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
Buttons, RadioButton, CheckBox, etc
DropDownList
ComboBox and ListBox (obsolete as of Q2 2010)
ListView
Chart (obsolete as of Q1 2013)
Form
PageView
MultiColumn ComboBox
TextBox
Menu
RichTextEditor
RichTextBox (obsolete as of Q3 2014 SP1)
Panelbar (obsolete as of Q2 2010)
Tabstrip (obsolete as of Q2 2010)
PivotGrid and PivotFieldList
MaskedEditBox
CommandBar
PdfViewer and PdfViewerNavigator
ListControl
Carousel
Diagram, DiagramRibbonBar, DiagramToolBox
Panorama
GanttView
New Product Suggestions
Toolstrip (obsolete as of Q3 2010)
AutoCompleteBox
Label
VirtualGrid
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
Documentation
SplitContainer
Map
DesktopAlert
ProgressBar
Rotator
TrackBar
MessageBox
CheckedDropDownList
SpinEditor
StatusStrip
CheckedListBox
Wizard
ShapedForm
SyntaxEditor
TextBoxControl
LayoutControl
CollapsiblePanel
Conversational UI, Chat
DateTimePicker
CAB Enabling Kit
TabbedForm
DataEntry
GroupBox
ScrollablePanel
WaitingBar
ImageEditor
ScrollBar
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
ColorDialog
FileDialogs
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
BindingNavigator
PopupEditor
RibbonForm
TaskBoard
Barcode
Styling
ColorBox
PictureBox
Callout
VirtualKeyboard
FilterView
Accessibility
DataLayout
NavigationView
ToastNotificationManager
CalculatorDropDown
Localization
TimePicker
ValidationProvider
FontDropDownList
Licensing
BreadCrumb
ButtonTextBox
LocalizationProvider
Dictionary
Overlay
Security
Separator
SparkLine
TreeMap
StepProgressBar
SplashScreen
ToolbarForm
NotifyIcon
Rating
TimeSpanPicker
BarcodeView
Calculator
OfficeNavigationBar
Flyout
TaskbarButton
HeatMap
SlideView
PipsPager
+? more
Top users last month
horváth
Top achievements
Rank 2
Iron
Iron
Steve
Top achievements
Rank 2
Iron
Erkki
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 2
Iron
Iron
Veteran
Jakub
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
horváth
Top achievements
Rank 2
Iron
Iron
Steve
Top achievements
Rank 2
Iron
Erkki
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 2
Iron
Iron
Veteran
Jakub
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?