Telerik Forums
UI for WinForms Forum
1 answer
174 views
Hi,

In the code below I have a dataset connected to a radTreeView. It is recursive and it works. When I try to filter the dataset with the .Select command the radTreeView knows there is data there but the displaymember stays blank - meaning no text in the tree. Why?

Thanks,
Karl 

private void BindLangDataToTree()
{
    this.radTreeView1.DisplayMember = "Thema_" + myLang; ;
    this.radTreeView1.ParentMember = "pid";
    this.radTreeView1.ChildMember = "id";
    this.radTreeView1.ValueMember = "id";
    radTreeView1.DataSource =  ds_Baum.Tables["Baum"];//.Select("Schule='" + mySchuleID + "'");
}
Julian Benkov
Telerik team
 answered on 13 Jun 2012
3 answers
220 views
Hi,

I have a ComboBoxColumn that is bound to a datatable.  One of the options in the datatable is "None" with a value of DBNull.  I have the DisplayMember and ValueMember set and everything works just fine, except when I choose "None" in the list and move off the row. The column with the ComboBox is empty instead of "None".  Any other value displays the lookup text just fine.

Any ideas?
Julian Benkov
Telerik team
 answered on 13 Jun 2012
1 answer
439 views
Hi,
Could I make RadGridView control's initialization faster? Currently first initialization of this control can take few seconds, what is quite long in case of dialog window, appearing on demand.

Sample code:

public partial class RadGridViewDialog : Form
{
    private RadGridView _grid;
  
    public RadGridViewDialog()
    {
        InitializeComponent();
    }
  
    private void btnInitialize_Click(object sender, EventArgs e)
    {
        _grid = new RadGridView();
          
        panel2.Controls.Add(_grid);
        _grid.Dock = DockStyle.Fill;
        _grid.BringToFront();
    }
  
    private void btnBuild_Click(object sender, EventArgs e)
    {
        using (_grid.DeferRefresh())
        {
            GridViewDataColumn firstColumn = new GridViewTextBoxColumn();
            firstColumn.HeaderText = "Name";
            _grid.Columns.Add(firstColumn);
            firstColumn.ReadOnly = true;
  
            GridViewDataRowInfo[] rows = new GridViewDataRowInfo[200];
  
            GridViewDataColumn secondColumn = new GridViewTextBoxColumn();
            secondColumn.HeaderText = "Value";
            _grid.Columns.Add(secondColumn);
            secondColumn.Width = 110;
            secondColumn.MinWidth = 70;
  
  
            int rowIndex = 0;
            for (int i = 0; i < rows.Length; i++)
            {
                rows[rowIndex] = new GridViewDataRowInfo(_grid.MasterView);
                rows[rowIndex].Cells[0].Value = "name" + i;
                rows[rowIndex].Cells[1].Value = "value" + i;
                rowIndex++;
            }
            firstColumn.IsPinned = true;
            _grid.Rows.AddRange(rows);
            firstColumn.BestFit();
        }
    }
}


After first opening this form, when user clicks on btnInitialize button application is freezing for few seconds, clicking on btnBuild button is much faster. Second and next clicks on btnInitialize (no matter in the same or other dialog in the same application) are faster too.

I've noticed that it's a reason of calling:
Telerik.WinControls.Themes.ControlDefault.ExternalControlsThemeHelper.LoadGridThemes()
in the static constructor of class Telerik.WinControls.UI.RadGridViewElement.

Is it possible to speed up first initialization of this class?

Regards
Stefan
Telerik team
 answered on 13 Jun 2012
3 answers
113 views
Hi,

This is the first time I'm installing new releases from Telerik. Previously i'm using Q1 controls, now with the release of Q2 controls, I just download it from my account and install it. But when I go to Control Panel, i see both Q1 and Q2 controls being installed, is that normal? Or do I need to uninstall Q1 product?

Thank you.

Regards,
Jenson
Andrey
Telerik team
 answered on 12 Jun 2012
5 answers
260 views
My gridview automatically expands a group when accessed that is in the middle of the grid so it forces the user to collapse the group and then scroll to the top of the grid. When I ungroup the data, the grid will just select a row. I basically need nothing to be expanded or selected by default but I do not see (or can not find) any options or documentation on solving this.


Edit: So it seems that it is selecting the first row from my database if this helps any.

Thanks,
Kyle
MARIANO
Top achievements
Rank 1
 answered on 12 Jun 2012
8 answers
661 views
Hi! I'm new to Telerik controls. I have radgridview control with "Edit" commandcolumn. When I click "Edit" button I want to show/open panel (or other container) with full of primitive controls (such as dropdownlist, textbox, radiobutton etc.) just below row that must be edited. After data entering in the panel i want to click "Save button" (in the panel or elsewhere) and row updated with new values. Is it possible to do it with radgridview? In asp.net ajax Q1 controls there is a NestedViewTemplate that you can insert to RadGrid element. Is there a similiar way in WinForm RadGridView? I am using Q2 Winform controls, Visual Studio 2008, C# prgramming language. 
Thanks
Marcel
Top achievements
Rank 1
 answered on 12 Jun 2012
5 answers
195 views
Hello,
Can i use your original theme ? and edit it ?
if yes please tell me where i can find Theme File .. what i have to do ...
Thank you
Nikolay
Telerik team
 answered on 12 Jun 2012
4 answers
431 views
How do I set the width of a CommandBarTextBox control?  It appears to reset itself to 60 of I change Size or Bounds in the designer, and if I set AutoSize to false all of the controls get mashed together and the layout looks atrocious.  What am I missing?

Thanks.
Chris Ward
Top achievements
Rank 1
 answered on 12 Jun 2012
1 answer
134 views
I have just upgraded the carousel control with latest version (2012.2.608.40), After upgrading the animation of the control is broken. i.e. in 2 of 5 times items do not move correctly along the path and end up on random spots within the control. I am using this control as a theme selector so when the selectedIndex is changed it also switch the theme while doing the animation. 

P.S Animation may be conflicting with theme switching but it was working OK before.  I have attached 2 screenshot of what a normal layout should be and one that is screwed up.

Please help.
Jack
Telerik team
 answered on 12 Jun 2012
3 answers
289 views
Hello!

I have a issue with the cellPaint-Event (virtualmodus is off).
In the Event I call a method where I draw the Background and the text of a cell. If the first cell of the current row has a special Tag, then I want to draw the text across all columns.
Therefore I use the bounds-Property of the RowElement.
But instead of drawing the text from the first cell across all other columns, the text is drawn within each cell. Why does this happen?
I explicitly set the Graphics.Clip to the Bounds of the RowElement.

See attached image for the issue.
There is also another issue where the background is drawn "behind" the scrollbar.

Just by the way: Can I set a ColumnSpan for a specific cell?

Here is my code for painting the cell:
private void drawTitle(GridViewCellPaintEventArgs e)
{
    var groupText = grid.Rows[e.Cell.RowIndex].Cells[0].Tag as string;
    var font = new Font(SystemFonts.MessageBoxFont, FontStyle.Regular | FontStyle.Underline);
     
    //region to draw is the entire row
    e.Graphics.Clip = new System.Drawing.Region(e.Cell.RowElement.Bounds);
    e.Graphics.Clear(Color.PeachPuff);
    e.Graphics.DrawString(groupText, font, Brushes.Blue, Point.Empty);
     
    e.Cell.RowElement.DrawBorder = false;
    e.Cell.RowElement.BorderWidth = 0;
    e.Cell.DisableHTMLRendering = true;
    e.Cell.CanFocus = false;
}


Thanks in advance!
Jack
Telerik team
 answered on 12 Jun 2012
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
PdfViewer and PdfViewerNavigator
CommandBar
ListControl
Carousel
GanttView
Diagram, DiagramRibbonBar, DiagramToolBox
Panorama
New Product Suggestions
VirtualGrid
Toolstrip (obsolete as of Q3 2010)
Label
AutoCompleteBox
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
SplitContainer
Documentation
Map
DesktopAlert
CheckedDropDownList
ProgressBar
MessageBox
TrackBar
Rotator
SpinEditor
CheckedListBox
StatusStrip
Wizard
CollapsiblePanel
LayoutControl
ShapedForm
SyntaxEditor
TextBoxControl
Conversational UI, Chat
DateTimePicker
TabbedForm
CAB Enabling Kit
WaitingBar
GroupBox
DataEntry
ScrollablePanel
ScrollBar
ImageEditor
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
FileDialogs
ColorDialog
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
NavigationView
BindingNavigator
RibbonForm
Styling
Barcode
PopupEditor
TaskBoard
Callout
ColorBox
PictureBox
FilterView
Accessibility
VirtualKeyboard
DataLayout
Licensing
ToastNotificationManager
ValidationProvider
CalculatorDropDown
Localization
TimePicker
BreadCrumb
ButtonTextBox
FontDropDownList
BarcodeView
Overlay
Security
LocalizationProvider
Dictionary
TreeMap
StepProgressBar
SplashScreen
Flyout
Separator
SparkLine
ToolbarForm
NotifyIcon
DateOnlyPicker
AI Coding Assistant
Rating
TimeSpanPicker
Calculator
OfficeNavigationBar
TaskbarButton
HeatMap
SlideView
PipsPager
AIPrompt
TaskDialog
TimeOnlyPicker
SpeechToTextButton
SmartPasteButton
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?