Telerik Forums
UI for WinForms Forum
1 answer
143 views

I think that there is a samo memory leak in  RichTextEditorRibbonBar, so let me show you my very simple scenario:

One empty telerik radform with just one RichTextEditorRibbonBar.

The steps:

1) Show form

2) Close form

3) Show form again

...

The result is new 30-50M in memory on each new form initsialization.

Plese give me some clue to deal with this problem.

Regards,

Simeon

Stefan
Telerik team
 answered on 07 Jul 2015
4 answers
238 views
I'm a bit new to the RadControls, and C# in general, so bear with me if the trouble I am facing is due to some terribad implementation. Anyway, here is the problem.

I have a single, form that has a number of radGridViews on it. Most of the grids are very simple lists with a schema that consists of not much more than an 'ID'{int} and a 'Name'{string}. I also have one master grid with a number of GridViewComboBoxColums that reference the aforementioned lists. I'm using entity framework models for the datasources, which I assign using the below

VendorManagerEntities context = new VendorManagerEntities();
 
protected override void OnLoad(EventArgs e)
{
    base.OnLoad(e);
 
    contactBindingSource.DataSource = context.Contacts;
    statusBindingSource.DataSource = context.Status;
    priorityBindingSource.DataSource = context.Priorities;
    categoryBindingSource.DataSource = context.Categories;
}
Note: The RadGridViews and GridViewComboBoxColums are sharing the same DataSources, a.k.a. I have a grid for status's and a combo box on another grid that both use the statusBindingSource.

When I start the application it populates the grids, columns, and combo boxes from the database; no problem is had. If I then add a row, new value, to one of the Grids that value will show up in the corresponding combobox, but if I select the new value, which apears correctly in the drop down list, the cell will be blank. The correct value is selected, and it submits correctly to the database/model, but it does not display. I suspect that is has something to do with the DisplayMember, but I'm not sure. If I restart the program, and the form is recreated, the new values that were gotten from the database display correctly. What I would like is for the new values to display in their cells, without having to close and restart the form application.

I warn that most of the grid creation was done with the designer, so I am hesitant to post too much of that generated code, but I'll try and get the important bits in here

private void InitializeComponent()
{
this.radGrid_Contacts = new Telerik.WinControls.UI.RadGridView();  // Contacts is "supergrid" that has a ton of combo boxes
this.contactBindingSource = new System.Windows.Forms.BindingSource(this.components);
((System.ComponentModel.ISupportInitialize)(this.buyerBindingSource)).BeginInit();
 
this.radGrid_Statuses = new Telerik.WinControls.UI.RadGridView(); // Status is a simple list, every status wants to some day be part of a combobox
this.statusBindingSource = new System.Windows.Forms.BindingSource(this.components);
((System.ComponentModel.ISupportInitialize)(this.statusBindingSource)).BeginInit();
 
// ...
 
//
// Contact Rad Grid
//
this.radGrid_Contacts.MasterTemplate.AutoGenerateColumns = false;
this.radGrid_Contacts.MasterTemplate.AutoSizeColumnsMode = Telerik.WinControls.UI.GridViewAutoSizeColumnsMode.Fill;
gridViewDecimalColumn1.DataType = typeof(int);
gridViewDecimalColumn1.EnableExpressionEditor = false;
gridViewDecimalColumn1.FieldName = "ID";
gridViewDecimalColumn1.HeaderText = "ID";
gridViewDecimalColumn1.IsAutoGenerated = true;
gridViewDecimalColumn1.Name = "ID";
gridViewDecimalColumn1.ReadOnly = true;
 
gridViewComboBoxColumn4.DataSource = this.statusBindingSource;
gridViewComboBoxColumn4.DataType = typeof(int);
gridViewComboBoxColumn4.DisplayMember = "Name";
gridViewComboBoxColumn4.EnableExpressionEditor = false;
gridViewComboBoxColumn4.FieldName = "Status_ID";
gridViewComboBoxColumn4.HeaderText = "Status";
gridViewComboBoxColumn4.Name = "Status_ID";
gridViewComboBoxColumn4.ValueMember = "ID";
gridViewComboBoxColumn4.Width = 129;
 
this.radGrid_Contacts.MasterTemplate.Columns.AddRange(new Telerik.WinControls.UI.GridViewDataColumn[] {
gridViewDecimalColumn1,
gridViewComboBoxColumn4,
gridViewCommandColumn1});
this.radGrid_Contacts.MasterTemplate.DataSource = this.contactBindingSource;
this.radGrid_Contacts.MasterTemplate.DataSource = this.contactBindingSource;
 
this.contactBindingSource.DataSource = typeof(VendorManager.Contact);
 
//
// radGrid_Statuses
//
gridViewDecimalColumn6.DataType = typeof(int);
gridViewDecimalColumn6.EnableExpressionEditor = false;
gridViewDecimalColumn6.FieldName = "ID";
gridViewDecimalColumn6.HeaderText = "ID";
gridViewDecimalColumn6.IsAutoGenerated = true;
gridViewDecimalColumn6.IsVisible = false;
gridViewDecimalColumn6.Name = "ID";
gridViewDecimalColumn6.Width = 301;
gridViewTextBoxColumn23.EnableExpressionEditor = false;
gridViewTextBoxColumn23.FieldName = "Name";
gridViewTextBoxColumn23.HeaderText = "Status Name";
gridViewTextBoxColumn23.IsAutoGenerated = true;
gridViewTextBoxColumn23.Name = "Name";
gridViewTextBoxColumn23.Width = 909;
 
gridViewTextBoxColumn24.DataType = typeof(VendorManager.TrackableCollection<VendorManager.Contact>);
gridViewTextBoxColumn24.EnableExpressionEditor = false;
gridViewTextBoxColumn24.FieldName = "Contacts";
gridViewTextBoxColumn24.HeaderText = "Contacts";
gridViewTextBoxColumn24.IsAutoGenerated = true;
gridViewTextBoxColumn24.IsVisible = false;
gridViewTextBoxColumn24.Name = "Contacts";
gridViewTextBoxColumn24.Width = 151;
 
this.radGrid_Statuses.MasterTemplate.Columns.AddRange(new Telerik.WinControls.UI.GridViewDataColumn[] {
gridViewDecimalColumn6,
gridViewTextBoxColumn23,
gridViewTextBoxColumn24,
gridViewTextBoxColumn25});
this.radGrid_Statuses.MasterTemplate.DataSource = this.statusBindingSource;
this.radGrid_Statuses.Name = "radGrid_Statuses";
 
}


I hope I explained my problem thorougly, if not please tell me so that I can elaborate on anything important that I missed. Thank you in advance for the help.


-Joel


EDIT: Quite interstingly, if I right click and clear the value on the cell it displays correctly.
Stefan
Telerik team
 answered on 07 Jul 2015
1 answer
487 views

I have a from with a number of RadButton elements each of which contains a square Image.

When the application is maximized I want all of the images to remain square when the elements are resized.

Can I re-adjust the sizes after the RadButton elements are resized?

If not, can I lock the aspect ratio of the Images so that resizing the RadButton elements does not distort them?

Stefan
Telerik team
 answered on 07 Jul 2015
1 answer
198 views

I am having an issue with the filter option crashing with radgridview.

To reproduce, create a radgridview as I describe below.

Run the program

Quickly click around in the cells of the table a few times, making sure to drag your mouse a bit so to select a few rows on some of the clicks.

Then quickly click the filter. (sometimes takes a few tries)

I get the following error

 

System.NullReferenceException: Object reference not set to an instance of an object. 

   at Telerik.WinControls.UI.GridRowBehavior.DoMultiFullRowSelect(GridCellElement currentCell, Point currentLocation)
   at Telerik.WinControls.UI.GridRowBehavior.DoMouseSelection(GridCellElement currentCell, Point currentLocation)
   at Telerik.WinControls.UI.GridRowBehavior.ProcessMouseSelection(Point mousePosition, GridCellElement currentCell)
   at Telerik.WinControls.UI.GridRowBehavior.OnMouseMove(MouseEventArgs e)
   at Telerik.WinControls.UI.BaseGridBehavior.OnMouseMove(MouseEventArgs e)
   at Telerik.WinControls.UI.RadGridView.OnMouseMove(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseMove(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at Telerik.WinControls.RadControl.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
   at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
   at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
   at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
   at System.Windows.Forms.Application.Run(Form mainForm)
   at BeaconQuerySource.Program.Main(String[] args)

 

To create the grid do the following.

 Make a RadGridView with the following options (not sure if all are important but the filter and multiselect are) 

this.gridConnectedSessions.MasterTemplate.AutoSizeColumnsMode = Telerik.WinControls.UI.GridViewAutoSizeColumnsMode.Fill;

this.gridConnectedSessions.MasterTemplate.EnableAlternatingRowColor = true;
this.gridConnectedSessions.MasterTemplate.EnableFiltering = true;

this.gridConnectedSessions.MasterTemplate.MultiSelect = true;

(leave the rest as the default options)

Add 3 columns to the grid

Add 5 rows of data to the grid (I used the following)

radGridView1.Rows.Add("test1","test1","test1");
radGridView1.Rows.Add("test2", "test2", "test2");
radGridView1.Rows.Add("test3", "test3", "test3");
radGridView1.Rows.Add("test4", "test4", "test4");
radGridView1.Rows.Add("test5", "test5", "test5");

 

Any help would be appreciated, thank you.

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 06 Jul 2015
11 answers
865 views
Hello

I'm actually meeting a problem with Telerik control disposing, using the Q3 2010.3.10.1109.

I joined a screenshot showing an Ant Profiler Analysis, after we disposed manually all our Telerik Controls.

Actually, some RadPropertyValues and others things are not disposed.
Maybe We are doing something wrong while disposing.

Can you pelase tell is where these RadPropertyValues are coming from, and if it's possible to dispose it as all others telerik resources on the screenshot?

For your information, we added dispose() methods for each telerik controls.

Thanks for your lights
Hristo
Telerik team
 answered on 06 Jul 2015
1 answer
174 views
how can i get transparent color on dockstrip? i change back color on RadPageViewContentAreaElement to transparent and switch gradient style to solid but nothing happen.
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 03 Jul 2015
1 answer
847 views

This is a question specifically for WinForms but the question is the same as below: 

http://www.telerik.com/forums/radgridview-scroll-position-reset-after-rebind 

Basically, what object and parameters do I have to access within the RadGridView to get my scroll position, so that I can reset it to that position after a rebind.

Stefan
Telerik team
 answered on 02 Jul 2015
3 answers
131 views

Hello Telerik,

I tried to translate the control into german.

How can I prevent the behavior, which is shown in the picture. (Wordwrap and cut off).

 

Greetings

 

PS: Yes, we used also font scaling.

Stefan
Telerik team
 answered on 02 Jul 2015
1 answer
207 views

Hi,

 In my code I'm adding appointments to a radScheduler like this:

 Dim app As New Appointment

app = New Appointment(Convert.ToDateTime(dr("StartTime")), Convert.ToDateTime(dr("EndTime")))

app.ToolTipText = "Some text"

 

How can I set a delay time for the tooltip, i.e. how long the tooltip text is displayed?

 

Regards,

Pirjo

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 02 Jul 2015
9 answers
432 views

How do I prevent a ToolTabStrip from being disposed when it has no child panels? I'd like to allow users to redock child panels into a ToolTabStrip even if there are no child panels left.

At the moment I am getting an error "Changing children collection of an already disposed element" when the redocking is attempted.

Thanks,

 

 -Lou

Lou
Top achievements
Rank 1
 answered on 01 Jul 2015
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
VirtualGrid
Toolstrip (obsolete as of Q3 2010)
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
VirtualKeyboard
DataLayout
Licensing
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
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
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
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?