Telerik Forums
UI for WinForms Forum
2 answers
138 views
hello,

i have a RadRibbonForm that has a skewed icon in the Form's titlebar.

i have removed and replaced dozens of times - it does not help.

i cannot start over on a new form - i have too much invested in this form already.

does anyone have any ideas of how to resolve this?  what property is set to make it behave this way?



Tops Software
Top achievements
Rank 2
 answered on 29 Jun 2013
2 answers
261 views
I want to prevent a user from using the property grid context menu to reset a value that has changed. I tried setting the IsModified property to false, but it is read-only. Is there another way to make sure the "Reset" item in the context menu is always disabled for a specific property grid item?
Paul
Top achievements
Rank 1
 answered on 28 Jun 2013
1 answer
125 views
Well, may i don't understand something in this page http://www.telerik.com/help/winforms/gridview-exporting-data-export-to-csv.html
or i have a missing dll?

Imports Telerik.WinControls.Data
Imports Telerik.WinControls.UI.Export
Imports Telerik.WinControls
Imports System.IO
 
 
 
Private Sub ToolStripButton2_Click(sender As Object, e As EventArgs) Handles ToolStripButton2.Click
        Dim exporter As ExportToCSV = New ExportToCSV(Me.RadGridView1)
 
        exporter.FileExtension = "csv"
 
        Dim camara As String = "C:\Users\FTL\Documents"
        exporter.RunExport(camara)
 
    End Sub
what I'm doing wrong?  i'll appreciate any help you can give me, thanks.

Paul
Telerik team
 answered on 28 Jun 2013
7 answers
179 views
I would like to go to the database every time a user inputs a filter and then clicks on the filter button.
So 2 things are different here.
  1. Filter does not get applied as user types in the filter, but only when user clicks on the filter button for that column.
  2. When user clicks on the filter button, then a new result set is returned from database based on filter condition. The results of this filter query will re-bind the database.

Thanks
Ivan Petrov
Telerik team
 answered on 28 Jun 2013
8 answers
236 views
Private Sub RadDateTimePickerEndDate_Opened(ByVal sender As Object, ByVal e As System.EventArgs) Handles RadDateTimePickerEndDate.Opened
 Dim table As CalendarTableElement = TryCast(TryCast(Me.RadDateTimePickerEndDate.DateTimePickerElement.GetCurrentBehavior(), RadDateTimePickerCalendar).Calendar.CalendarElement.CalendarVisualElement.Children(0).Children(1), CalendarTableElement)
        For Each cell As CalendarCellElement In table.Children
            If cell.Date < Me.DateTimePickerEndDateMin Then
                cell.BackColor = Color.Red
            Else
                cell.BackColor = Color.Green
            End If
            If cell.[Date].DayOfWeek = DayOfWeek.Saturday Or cell.[Date].DayOfWeek = DayOfWeek.Sunday Then
                cell.BackColor = Color.Transparent
            End If
        Next
    End Sub

Hello All,
This is the code I am using to set the back ground color of the cells in the calendar control based on the min date.
1)I open the calendar  the back color for all the dates less than the min date is showing up as red. Let us assume the min date is 6/12/2000
Now when I go to next month(i.e., 7/12/2000) the back color for all the cells in that month is supposed to be green. But this is not the case. Whats happening is that some of the Cells color is still Red and the others are green. But if i reopen the Calendar all the dates show up as Green. Now if I go back to 6/12/2000 all the dates including dates less than 12 th of June are showing up as Green too.
Is there any other event in which this code needs to be executed when i change the month using the arrow on the top of raddatepicker. I am using raddatetimepicker for winforms. Q3 2010 version. I do not see a viewchanged event here. Any help would be appreciated.

Thanks a lot.
Stefan
Telerik team
 answered on 28 Jun 2013
2 answers
216 views
Hello,

I would like to disable the ContextMenu popup fade-in animation for a RadDock, but I cannot find where to do this.

I know how to disable the contextmenu animation for a RadGrid, for example, by subscribing to the grid's ContextMenuOpening event and using e.ContextMenu.AnimationEnabled = false; when the event fires.

However, the RadDock context menus are handled by the ContextMenuService, which only has the ContextMenuDisplaying event, and in this events handler, there is not a reference to the actual context menu object, just a list of the menuitems and the upcoming display position.

I know that ThemeResolutionService.AllowAnimations = false; will accomplish this, but this will also disable all animations across the application, which I do not want to do. I just want to disable the ContextMenu fade-in animation.

Any advice on how to do this?

Thanks,


Michelle
Michelle
Top achievements
Rank 1
 answered on 28 Jun 2013
3 answers
1.0K+ views
Error:  Cannot access a disposed object. Object name: 'GridViewSynchronizationService'.

Scenario: This error only appears to happen when I'm utilizing an EventLogEntryCollection as the datasource and refreshing the datasource via a timer event. The form is a simple event log monitor.

The error occurs randomly on either of these lines (this is from within a custom control):

this.dgResults.DataSource = null;
this.dgResults.DataSource = this.DataCache;

The above DataCache object is a dynamic property that is populated by the code below.

EventLog e = new EventLog(EDI.Definitions.EVENT_LOG, ConfigurationManager.AppSettings["EventLogServerName"]);
this.dgResults.DataSource = e.Entries;

The above snippet is from a form that is consuming the custom datagrid control (so the dgResults object is distinguishable for anyone reading).

I can't recreate the issue as it just randomly appears from time to time.

Hopefully this is a known issue of some type and there is an easy fix.  I saw that clearing the relations might work, but that doesn't seem to be working for me.

Ideas anyone?  Thanks in advance! Let me know if more is required.

Peter
Telerik team
 answered on 27 Jun 2013
1 answer
92 views
Hello, I have a question. How can I edit themes. Radcontrols already come with a few themes but none I really like, so I want to make my own how can I edit the themes and add them just like a regular theme for me to use every time?
George
Telerik team
 answered on 27 Jun 2013
10 answers
1.7K+ views
I got a datetimepicker. Displaying short date format. If I do the size of the control to suit that format, the drop down showing the month is very small. User can use the handle in the bottom right corner to resize it, but I want it to show nicely to start with. Any way to do that other than increasing the width of the datetimepicker (which leave a lot of blank space to the right)?
Stefan
Telerik team
 answered on 26 Jun 2013
3 answers
154 views
I have a gridview bound to an BindingList<> and it allows the user to add a new row.  Whenever the user clicks on the add new row area, the grid immediately inserts 2 new rows  one of them overlaps the area with the prompt "Click here to add a new row".  Once the user is done editing one of the rows.  An IndexOutOfRangeException is thrown when the grid tries to set the value to the extra row.  How can I avoid this?

public NoteHistoryControl()
        {
            InitializeComponent();
            this.noteHistoryGridView.DataSource = new BindingList<Note>(this._noteHistory);
        }
 
 
        private void noteHistoryGridView_CellValueChanged(object sender, Telerik.WinControls.UI.GridViewCellEventArgs e)
        {
            GridViewDataColumn column = e.Column as GridViewDataColumn;
            if (column != null && column.FieldName == "Text")
            {
                this._noteText = e.Value.ToString();
                this.noteHistoryGridView.MasterGridViewTemplate.AllowAddNewRow = false;
            }
        }

private void InitializeComponent()
        {
            Telerik.WinControls.UI.GridViewTextBoxColumn gridViewTextBoxColumn1 = new Telerik.WinControls.UI.GridViewTextBoxColumn();
            Telerik.WinControls.UI.GridViewDateTimeColumn gridViewDateTimeColumn1 = new Telerik.WinControls.UI.GridViewDateTimeColumn();
            Telerik.WinControls.UI.GridViewTextBoxColumn gridViewTextBoxColumn2 = new Telerik.WinControls.UI.GridViewTextBoxColumn();
            Telerik.WinControls.UI.GridSortField gridSortField1 = new Telerik.WinControls.UI.GridSortField();
            this.panel1 = new System.Windows.Forms.Panel();
            this.noteLabel = new System.Windows.Forms.Label();
            this.noteHistoryGridView = new Telerik.WinControls.UI.RadGridView();
            this.panel1.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(this.noteHistoryGridView)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(this.noteHistoryGridView.MasterGridViewTemplate)).BeginInit();
            this.SuspendLayout();
            //
            // panel1
            //
            this.panel1.Controls.Add(this.noteLabel);
            this.panel1.Dock = System.Windows.Forms.DockStyle.Top;
            this.panel1.Location = new System.Drawing.Point(0, 0);
            this.panel1.Name = "panel1";
            this.panel1.Padding = new System.Windows.Forms.Padding(3);
            this.panel1.Size = new System.Drawing.Size(400, 28);
            this.panel1.TabIndex = 0;
            //
            // noteLabel
            //
            this.noteLabel.AutoSize = true;
            this.noteLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.noteLabel.Location = new System.Drawing.Point(6, 6);
            this.noteLabel.Margin = new System.Windows.Forms.Padding(3);
            this.noteLabel.Name = "noteLabel";
            this.noteLabel.Size = new System.Drawing.Size(44, 16);
            this.noteLabel.TabIndex = 1;
            this.noteLabel.Text = "Notes";
            //
            // noteHistoryGridView
            //
            this.noteHistoryGridView.BackColor = System.Drawing.SystemColors.Control;
            this.noteHistoryGridView.Cursor = System.Windows.Forms.Cursors.Default;
            this.noteHistoryGridView.Dock = System.Windows.Forms.DockStyle.Fill;
            this.noteHistoryGridView.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F);
            this.noteHistoryGridView.ForeColor = System.Drawing.SystemColors.ControlText;
            this.noteHistoryGridView.ImeMode = System.Windows.Forms.ImeMode.NoControl;
            this.noteHistoryGridView.Location = new System.Drawing.Point(0, 28);
            //
            //
            //
            this.noteHistoryGridView.MasterGridViewTemplate.AddNewRowPosition = Telerik.WinControls.UI.PinnedRowPosition.Bottom;
            this.noteHistoryGridView.MasterGridViewTemplate.AllowColumnChooser = false;
            this.noteHistoryGridView.MasterGridViewTemplate.AllowColumnReorder = false;
            this.noteHistoryGridView.MasterGridViewTemplate.AllowDeleteRow = false;
            this.noteHistoryGridView.MasterGridViewTemplate.AllowDragToGroup = false;
            this.noteHistoryGridView.MasterGridViewTemplate.AllowEditRow = false;
            this.noteHistoryGridView.MasterGridViewTemplate.AutoGenerateColumns = false;
            this.noteHistoryGridView.MasterGridViewTemplate.AutoSizeColumnsMode = Telerik.WinControls.UI.GridViewAutoSizeColumnsMode.Fill;
            gridViewTextBoxColumn1.AllowFiltering = false;
            gridViewTextBoxColumn1.AllowGroup = false;
            gridViewTextBoxColumn1.AllowHide = false;
            gridViewTextBoxColumn1.FieldAlias = "columnNote";
            gridViewTextBoxColumn1.FieldName = "Text";
            gridViewTextBoxColumn1.HeaderText = "Note";
            gridViewTextBoxColumn1.HeaderTextAlignment = System.Drawing.ContentAlignment.MiddleLeft;
            gridViewTextBoxColumn1.MinWidth = 50;
            gridViewTextBoxColumn1.Multiline = true;
            gridViewTextBoxColumn1.UniqueName = "columnNote";
            gridViewTextBoxColumn1.Width = 215;
            gridViewTextBoxColumn1.WrapText = true;
            gridViewDateTimeColumn1.AllowFiltering = false;
            gridViewDateTimeColumn1.AllowGroup = false;
            gridViewDateTimeColumn1.AllowHide = false;
            gridViewDateTimeColumn1.DataType = typeof(System.DateTime);
            gridViewDateTimeColumn1.FieldAlias = "EntryDate";
            gridViewDateTimeColumn1.FieldName = "EntryDate";
            gridViewDateTimeColumn1.HeaderText = "Entry Date";
            gridViewDateTimeColumn1.HeaderTextAlignment = System.Drawing.ContentAlignment.MiddleLeft;
            gridViewDateTimeColumn1.MinWidth = 50;
            gridViewDateTimeColumn1.ReadOnly = true;
            gridViewDateTimeColumn1.UniqueName = "columnDate";
            gridViewDateTimeColumn1.Width = 215;
            gridViewTextBoxColumn2.AllowFiltering = false;
            gridViewTextBoxColumn2.AllowGroup = false;
            gridViewTextBoxColumn2.AllowHide = false;
            gridViewTextBoxColumn2.FieldAlias = "EntryUsername";
            gridViewTextBoxColumn2.FieldName = "EntryUsername";
            gridViewTextBoxColumn2.HeaderText = "Username";
            gridViewTextBoxColumn2.HeaderTextAlignment = System.Drawing.ContentAlignment.MiddleLeft;
            gridViewTextBoxColumn2.MinWidth = 50;
            gridViewTextBoxColumn2.ReadOnly = true;
            gridViewTextBoxColumn2.UniqueName = "columnUsername";
            gridViewTextBoxColumn2.Width = 215;
            this.noteHistoryGridView.MasterGridViewTemplate.Columns.Add(gridViewTextBoxColumn1);
            this.noteHistoryGridView.MasterGridViewTemplate.Columns.Add(gridViewDateTimeColumn1);
            this.noteHistoryGridView.MasterGridViewTemplate.Columns.Add(gridViewTextBoxColumn2);
            this.noteHistoryGridView.MasterGridViewTemplate.EnableGrouping = false;
            this.noteHistoryGridView.MasterGridViewTemplate.ShowRowHeaderColumn = false;
            gridSortField1.FieldAlias = "columnDate";
            gridSortField1.FieldName = "columnDate";
            this.noteHistoryGridView.MasterGridViewTemplate.SortExpressions.Add(gridSortField1);
            this.noteHistoryGridView.Name = "noteHistoryGridView";
            this.noteHistoryGridView.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.noteHistoryGridView.SelectionMode = Telerik.WinControls.UI.GridViewSelectionMode.CellSelect;
            this.noteHistoryGridView.ShowGroupPanel = false;
            this.noteHistoryGridView.Size = new System.Drawing.Size(400, 122);
            this.noteHistoryGridView.TabIndex = 1;
            this.noteHistoryGridView.ThemeName = "ControlDefault";
            this.noteHistoryGridView.CellValueChanged += new Telerik.WinControls.UI.GridViewCellEventHandler(this.noteHistoryGridView_CellValueChanged);
            //
            // NoteHistoryControl
            //
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.Controls.Add(this.noteHistoryGridView);
            this.Controls.Add(this.panel1);
            this.MinimumSize = new System.Drawing.Size(350, 125);
            this.Name = "NoteHistoryControl";
            this.Size = new System.Drawing.Size(400, 150);
            this.panel1.ResumeLayout(false);
            this.panel1.PerformLayout();
            ((System.ComponentModel.ISupportInitialize)(this.noteHistoryGridView.MasterGridViewTemplate)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(this.noteHistoryGridView)).EndInit();
            this.ResumeLayout(false);
            this.PerformLayout();
 
        }

Felipe
Top achievements
Rank 1
 answered on 26 Jun 2013
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
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
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?