Telerik Forums
UI for WinForms Forum
0 answers
91 views
hello
I would like to personalizzar elo schedule with the property grouptimeline as in the image I posted.
For example it is possible to reduce the height of the column of the rooms and enter the text horizontally?
Since I use the display in days, you can display only the number of the day without the name and in the bar of the period to appear also the year as well as the period from day to day.
To better understand how I plan to send you the picture I took of the schedule from the demo of telerik and an image created by me that shows the schedule as it should be.
Also since I with the schedule I will make the reservations for hotels modifcare and you can customize the panel for appointment as changing buttons, combo, the text etc. and manage the bailouts directly on the database.

thanks
Fabio Cirillo
Top achievements
Rank 1
 asked on 29 Oct 2013
2 answers
81 views
hi,
i disabled add,edit and delete appointment on Scheduler by canceling them:
private void ReservationRadScheduler_AppointmentDeleting(object sender, SchedulerAppointmentCancelEventArgs e)
        {
            e.Cancel = true;
        }
 
        private void ReservationRadScheduler_AppointmentDropping(object sender, AppointmentMovingEventArgs e)
        {
            e.Cancel = true;
        }
 
        private void ReservationRadScheduler_AppointmentEditDialogShowing(object sender, AppointmentEditDialogShowingEventArgs e)
        {
            e.Cancel = true;
        }
everything works fine at debugging and running on the developing computer
but after puplishing the application when i double click on the appointment an exception is thrown:
Exception Message:"value is lower than the minimum value"
this happens in EditAppointmentDialog.InitializeComponent() !!!!!!
George
Telerik team
 answered on 29 Oct 2013
1 answer
99 views
Hi,

I can't get the pan/scroll functionality to work when reloading the chartview.

Please see the code below. When I call the LoadChart function for the first time in form load event, it works fine. When it is called for the second time in button click event, the pan/scroll does not work (zoom works, however). As You can see, I clear the series and axes in the beginning, I tried both axes.clear and axes.purge, neither of them helps.

Private Sub Form1_Load(sender As Object, e As System.EventArgs) Handles Me.Load
 
     rcvSchedule.ShowPanZoom = True
     LoadChart()
 
  End Sub
 
  Private Sub LoadChart()
   
     rcvSchedule.Series.Clear()
     rcvSchedule.Axes.Purge()
     rcvSchedule.Area.View.Palette = KnownPalette.Metro
 
     Dim horizontalAxis As New CategoricalAxis
     horizontalAxis.LabelFitMode = Telerik.Charting.AxisLabelFitMode.Rotate
 
     Dim bar1DataSource As New List(Of CustomObject)()
     bar1DataSource.Add(New CustomObject() With {.Value1 = 250, .Category = "19.09.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 200, .Category = "30.09.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 25, .Category = "06.10.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 300, .Category = "17.10.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 300, .Category = "18.10.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 300, .Category = "19.10.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 300, .Category = "20.10.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 300, .Category = "21.10.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 300, .Category = "22.10.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 300, .Category = "23.10.2013"})
     bar1DataSource.Add(New CustomObject() With {.Value1 = 300, .Category = "24.10.2013"})
 
     Dim bar1 As New BarSeries()
     bar1.ValueMember = "Value1"
     bar1.CategoryMember = "Category"
     bar1.LegendTitle = "Tot."
     bar1.DataSource = bar1DataSource
     bar1.HorizontalAxis = horizontalAxis
     rcvSchedule.Series.Add(bar1)
 
    
  End Sub
 
  Private Sub RadButton1_Click(sender As System.Object, e As System.EventArgs) Handles RadButton1.Click
     LoadChart()
  End Sub

Regards,
Pirjo
George
Telerik team
 answered on 29 Oct 2013
2 answers
109 views
Hello,

I used to validate the presence of the scrollbars in the DataGridView by doing this:


var scrollBar = gvBrand.Controls.OfType<VScrollBar>().First();


but with the RadGridView I'm unable to do this... 

Is there an alternative ?

Thank you
Nuno
Top achievements
Rank 1
 answered on 28 Oct 2013
2 answers
82 views
Hi,

I've noticed that the RadTreeView font in the latest Q3 2013 release seems different to previous releases.  It's almost as if it's not anti-aliased (see attached screenshot of both Q2 and Q3 2013 treeviews in the Telerik demo app).

Any info would be much appreciated.

Regards,

Frazz 
Ralitsa
Telerik team
 answered on 28 Oct 2013
3 answers
199 views
hi
i want to filter the grid of multicolumncombobox by using filtering row so i use this code
 DataTable dt = new DataTable();
            dt.Columns.Add("id");
            dt.Columns.Add("Name");
            dt.Rows.Add("1", "a");
            dt.Rows.Add("2", "b");
            dt.Rows.Add("3", "c");
            radMultiColumnComboBox1.DataSource = dt;
            radMultiColumnComboBox1.EditorControl.EnableFiltering = true;
            radMultiColumnComboBox1.EditorControl.EnableCustomFiltering = true;
            radMultiColumnComboBox1.EditorControl.ShowFilteringRow = true;    ///by using this we only can see the filtering row

so i can see the filteringrow but it dosent work .i cant filter the grid of multicolumn and i cant do customfiltering like some thing we do in radgridviews.
please help me if you know a way to do it
Stefan
Telerik team
 answered on 28 Oct 2013
6 answers
275 views
Hello, 
I am using RadControls for WinForms 2011 Q3 
RadGridView,  it is in unbound mode.
 
I want to reorder the row. Say I drag the row 1 and drop it to row 4. 
but it does not work. I guess somehow I must miss something, please help.  thanks !

public init()
{
            InitializeComponent();
            InitializePreviewGrid();
            SubscribeForGridEvents(radGridViewPreview);    
}
        List<PreviewItem> _previewLists = new List<PreviewItem>();
        private void InitializePreviewGrid()
        {
            radGridViewPreview.AutoGenerateColumns = false;
            var imageCol = new GridViewImageColumn("DeleteIcon", "DeleteIcon");
            imageCol.HeaderText = "";
            imageCol.Width = 30;
            radGridViewPreview.Columns.Add(imageCol);

            var col = new GridViewTextBoxColumn("DisplayStr", "DisplayStr");
            col.Width = 350;
            radGridViewPreview.Columns.Add(col);

            col = new GridViewTextBoxColumn("ValueStr", "ValueStr");
            col.IsVisible = false;
            radGridViewPreview.Columns.Add(col);

            radGridViewPreview.AllowDeleteRow = false;
            radGridViewPreview.AllowAddNewRow = false;
            radGridViewPreview.AllowEditRow = false;
            radGridViewPreview.AutoScroll = true;
            radGridViewPreview.AllowAutoSizeColumns = true;

            radGridViewPreview.MasterTemplate.AllowRowReorder = true;
            radGridViewPreview.ReadOnly = true;
            radGridViewPreview.MultiSelect = true;
            radGridViewPreview.MasterTemplate.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;

            radGridViewPreview.GridBehavior = new CustomGridBehavior();
        }

        private void SubscribeForGridEvents(RadGridView grid)
        {
            dragDropService = grid.GridViewElement.GetService<RadDragDropService>();
            dragDropService.PreviewDragOver += dragDropService_PreviewDragOver;
            dragDropService.PreviewDragDrop += dragDropService_PreviewDragDrop;
            dragDropService.PreviewDragHint += dragDropService_PreviewDragHint;
            dragDropService.PreviewDropTarget += dragDropService_PreviewDropTarget;
            dragDropService.PreviewDragStart += dragDropService_PreviewDragStart;
        }

       void dragDropService_PreviewDragStart(object sender, PreviewDragStartEventArgs e)
        {
            //throw new NotImplementedException();
        }

        void dragDropService_PreviewDropTarget(object sender, PreviewDropTargetEventArgs e)
        {
            //throw new NotImplementedException();
        }
        
        private void dragDropService_PreviewDragDrop(object sender, RadDropEventArgs e)
        {
            var rowElement = e.DragInstance as GridDataRowElement;
            if (rowElement == null)
            {
                return;
            }

            var dropTarget = e.HitTarget as RadItem;
            var targetGrid = dropTarget.ElementTree.Control as RadGridView;
            if (targetGrid == null)
            {
                return;
            }

            var dragGrid = rowElement.ElementTree.Control as RadGridView;
            if (targetGrid != dragGrid)
            {
                e.Handled = true;

                var behavior = (CustomGridBehavior)dragGrid.GridBehavior;
                var dropTargetRow = dropTarget as GridDataRowElement;
                int index = dropTargetRow != null ? GetTargetRowIndex(dropTargetRow, e.DropLocation) : targetGrid.RowCount;
                MoveRows(targetGrid, dragGrid, behavior.SelectedRows, index);
            }
        }

        private void dragDropService_PreviewDragOver(object sender, RadDragOverEventArgs e)
        {
            if (e.DragInstance is GridDataRowElement)
            {
                e.CanDrop = e.HitTarget is GridDataRowElement || e.HitTarget is GridTableElement || e.HitTarget is GridSummaryRowElement;
            }
        }

        private void dragDropService_PreviewDragHint(object sender, PreviewDragHintEventArgs e)
        {
            GridDataRowElement dataRowElement = e.DragInstance as GridDataRowElement;

            if (dataRowElement != null && dataRowElement.ViewTemplate.MasterTemplate.SelectedRows.Count > 1)
            {
                //e.DragHint = new Bitmap(this.imageList1.Images[6]);
                e.UseDefaultHint = false;
            }
        }

        private void MoveRows(RadGridView targetGrid, RadGridView dragGrid, IList<GridViewRowInfo> dragRows, int index)
        {
            for (int i = dragRows.Count - 1; i >= 0; i--)
            {
                GridViewRowInfo row = dragRows[i];

                if (row is GridViewSummaryRowInfo)
                {
                    continue;
                }

                GridViewRowInfo newRow = targetGrid.Rows.NewRow();
                this.InitializeRow(newRow, row);
                targetGrid.Rows.Insert(index, newRow);
                row.IsSelected = false;
                dragGrid.Rows.Remove(row);
                index++;
            }
        }

        private void InitializeRow(GridViewRowInfo destRow, GridViewRowInfo sourceRow)
        {
            destRow.Cells["DisplayStr"].Value = sourceRow.Cells["DisplayStr"].Value;
            destRow.Cells["ValueStr"].Value = sourceRow.Cells["ValueStr"].Value;
        }

        private int GetTargetRowIndex(GridDataRowElement row, Point dropLocation)
        {
            int halfHeight = row.Size.Height / 2;
            int index = row.RowInfo.Index;

            if (dropLocation.Y > halfHeight)
            {
                index++;
            }

            return index;
        }
Stefan
Telerik team
 answered on 28 Oct 2013
1 answer
107 views
Hi,

I'm trying to intercept the paste event when the user has pressed control -v, to paste the clipboard contents as plain text.
But I can't work out where to start ?

Thanks
Euan
Dimitar
Telerik team
 answered on 28 Oct 2013
6 answers
535 views
I have what I hope is a simple problem.   I have a simple WinForms application in which I'm providing a generic ObservableCollection<> of a simple public business object type as a data source for a RadGridView (version Winforms 2011_1_11_419), .  

For whatever reason, i cannot get it to auto-sort by clicking on the column headers.  (My understanding after reading the Help is that this should be automatic if the "GridView.EnableSorting" and "GridView.MasterTemplate.EnableSorting" properties are both true).   I do have AutoGenerateColumns also set to True, since the business object is still evolving and gaining/adding/changing properties in between builds..

I've tried setting the grid's DataSource property directly to the ObservableCollection<MyObjectType>.  I've tried creating an intermediate BindingSource and setting the grid's DataSource to that.   I've tried creating several SortDescriptors for the columns on which I most need to sort.   I've tried removing all such SortDescriptors.   I've tried creating a custom SortableObservableCollection (which works in binding in WPF) instead of the ObservableCollection.   Etc. 

The data always displays correctly in the GridView; but doesn't sort or show sort direction indicators in the column headers.

There has to be something simple I'm missing.

Thanks!
-Bob
Michael
Top achievements
Rank 1
 answered on 27 Oct 2013
2 answers
109 views
from
Demo Application - RadControls for WinForms.
Gridview -> Custom Painting.

I want to move the drawing image in grid view.
- change cursor on mouse over
- drag and drop drawing
- show image moving 

please help me...
Lek
Top achievements
Rank 1
 answered on 26 Oct 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)
Chart (obsolete as of Q1 2013)
Form
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
Toolstrip (obsolete as of Q3 2010)
VirtualGrid
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
Conversational UI, Chat
DateTimePicker
CollapsiblePanel
TabbedForm
CAB Enabling Kit
GroupBox
WaitingBar
DataEntry
ScrollablePanel
ScrollBar
ImageEditor
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
ColorDialog
FileDialogs
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
Barcode
BindingNavigator
PopupEditor
RibbonForm
Styling
TaskBoard
Callout
ColorBox
PictureBox
FilterView
NavigationView
Accessibility
VirtualKeyboard
DataLayout
ToastNotificationManager
ValidationProvider
CalculatorDropDown
Licensing
Localization
TimePicker
ButtonTextBox
FontDropDownList
BarcodeView
BreadCrumb
Security
LocalizationProvider
Dictionary
Overlay
Flyout
Separator
SparkLine
TreeMap
StepProgressBar
SplashScreen
ToolbarForm
NotifyIcon
DateOnlyPicker
Rating
TimeSpanPicker
Calculator
OfficeNavigationBar
TaskbarButton
HeatMap
SlideView
PipsPager
AIPrompt
TaskDialog
TimeOnlyPicker
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?