Telerik Forums
UI for WinForms Forum
2 answers
227 views

Is it possible to use one RadDateTimePicker and set it up for a range of seven days?

So, lets say the control says DateTime.Today is 12/1/2017, and I want a start date of seven days prior to this date. How can I do this?

 

C#

 

Thanks,

Brian
Top achievements
Rank 1
Iron
Iron
 answered on 05 Dec 2017
8 answers
337 views

Hi,

am trying to make an app where the MDI parent is basically the container for the app pages..so don't want the MDI child titlebar in there at all.

Found on the forums that you open the child this way:

showform is the newly created form:

 With showForm
            .MdiParent = Me
            .WindowState = FormWindowState.Maximized
            .ShowIcon = False
            .ControlBox = False
            .MaximizeBox = False
            .MinimizeBox = False
            .FormBorderStyle = Windows.Forms.FormBorderStyle.None
            .ShowInTaskbar = False
            .Text = ""            
            .Show()
        End With

I always get 2 title bars and all the controls on the child title bar are active???? when I have disabled them. Also when I maximise the child..THEN I get the single title bar, which is what I want.....what is going on here as it appears the maximize code function and the button function are different...I want the button functionality in the code.

Am using version 2017.3.1017.40 and RadForms

 

Any ideas??

 

Dimitar
Telerik team
 answered on 05 Dec 2017
6 answers
316 views
I'm trying to set a column to be the row's detail column.  I am having trouble using the code as implemented in the demo.

            this.radGridView.DetailsColumn = this.radGridView.Columns["Notes"];

I am getting the error that the radgridview object does not contain detailscolumn.
Hristo
Telerik team
 answered on 05 Dec 2017
2 answers
150 views

Hello,

I created a ApplicationMenu in WinForms UI with icons and text in the menu-items.
On 1 item I created a sub-menu, but there shows up a second column (by default) which I dont want.
That was also the case first the first level of menu, but there I could fix this with a boolean property 'ShowTwoColumnDropdownmenu' on the applicationMenu itself. But there is no such property for a menu-item, or is there?

Please see again my attachment to clarify what I mean. (Pretty basic actually)

 

Martin
Top achievements
Rank 1
 answered on 05 Dec 2017
1 answer
289 views

I used radgridview and add row with programatic. (like GridView.Rows.Add() )

I must use auto resize and many row datas and it cause slow performance.

So i think if i use gridview paging, then gridview will always add just 20 rows (that i setted pagesize to 20) in internal when i view each pages.

But it is still too slow. Maybe it add all rows in spite of using RadGridView Paging.

I want to add only the number of pagesize rows and the total row datas was controlled by me. 

How should i gonna do?

Dimitar
Telerik team
 answered on 05 Dec 2017
3 answers
236 views

I want to create a custom calculator edit column based off the GridViewCalculatorColumn class (or RadCalculatorDropDownElement Class), but need some help getting started.  I need to remove several buttons, including the memory buttons and the decimal button (only positive integers are allowed), and round to an integer when %, SqRt, or another operation generates a decimal.

In addition I need to add a property that will pass in a default value, and add a button which will display this default value as its button text, and when pressed will replace the value with the default (each row could have its own default).

Please let me know if there is an example similar available, or any guidance that would help.

Thanks

Hristo
Telerik team
 answered on 05 Dec 2017
2 answers
124 views

Hello Telerik Team,

I'm using Excel-like filtering feature of RadGridView. I need to change font in PopUp.

Zan
Top achievements
Rank 1
 answered on 05 Dec 2017
21 answers
361 views
Hi,

I am creating an app that utilizes the RadPanorama tool. In the options tile, the user has the option to select what tiles they would like to see and what tiles that they would like to get rid of. However, when the user selects a tile to hide, the Rad Panorama leaves an empty space where that tile originally was. I would like the app to fill any blank spaces that might be created by the user in a tile row. I was wondering if the Rad Panorama had the functionality to move all the tiles back to the original start position (Row 0, Column 0) so that there are no awkward spaces when a tile is hidden? 

Thanks,

Derek O.
Dimitar
Telerik team
 answered on 04 Dec 2017
1 answer
77 views

Is there any property to select all the content in a radgrid clicking in the corner of the grid like in excel?

thanks in advance.

Dimitar
Telerik team
 answered on 04 Dec 2017
1 answer
128 views
<p>private BindingSource _bindingSource;<br>
        DataTable gridViewDataTable = new DataTable();<br>
<br>
        public SocPersonal()<br>
        {<br>
                      InitializeComponent();<br>            BaseGridBehavior gridBehavior = this.radGridView2.GridBehavior as BaseGridBehavior;<br>            gridBehavior.UnregisterBehavior(typeof(GridViewDataRowInfo));<br>            gridBehavior.RegisterBehavior(typeof(GridViewDataRowInfo), new CustomRowGridBehavior());<br><br>            RadDragDropService dragDropService = radGridView2.GridViewElement.GetService<RadDragDropService>();<br>            dragDropService.PreviewDragStart += svc_PreviewDragStart;<br>            dragDropService.PreviewDragOver += svc_PreviewDragOver;<br>            dragDropService.PreviewDragDrop += svc_PreviewDragDrop;<br>            gridViewDataTable.Columns.Add("key_socRabotnik", typeof(string));<br>            gridViewDataTable.Columns.Add("[ФИО]", typeof(string));<br><br>            radListView1.ListViewElement.DragDropService.PreviewDragOver += PreviewDragOver;<br>            radListView1.ListViewElement.DragDropService.PreviewDragDrop += PreviewDragDrop;<br><br>            MyRussionRadGridLocalizationProvider.CurrentProvider = new MyRussionRadGridLocalizationProvider();<br>            radGridView1.TableElement.Text = MyRussionRadGridLocalizationProvider.TableElementText;<br>            CheckForIllegalCrossThreadCalls = false;    <br>
            HandleCreated += Form_HandleCreated;<br>
        }<br>
<br>
        #region Drop<br>
        private void svc_PreviewDragStart(object sender, PreviewDragStartEventArgs e)<br>
        {<br>
            e.CanStart = true;<br>
        }<br>
<br>
        private void svc_PreviewDragOver(object sender, RadDragOverEventArgs e)<br>
        {<br>
            if (e.DragInstance is GridDataRowElement)<br>
            {<br>
                e.CanDrop = e.HitTarget is DetailListViewDataCellElement ||<br>
                            e.HitTarget is DetailListViewElement;<br>
            }<br>
        }<br>
<br>
        private void svc_PreviewDragDrop(object sender, RadDropEventArgs e)<br>
        {<br>
            DetailListViewDataCellElement targetCell = e.HitTarget as DetailListViewDataCellElement;<br>
            DetailListViewElement targetElement = e.HitTarget as DetailListViewElement;<br>
            GridDataRowElement draggedRow = e.DragInstance as GridDataRowElement;<br>
<br>
            if (draggedRow == null)<br>
            {<br>
                return;<br>
            }<br>
            ListViewDataItem item = new ListViewDataItem();<br>
            DataRow draggedDataBoundItem = ((DataRowView)draggedRow.RowInfo.DataBoundItem).Row;<br>
            if (targetElement != null)<br>
            {<br>
                ((RadListViewElement)targetElement.Parent).Items.Add(item);<br>
            }<br>
            if (targetCell != null)<br>
            {<br>
                BaseListViewVisualItem targetVisualItem = targetCell.RowElement;<br>
<br>
                int insertIndex = targetCell.Row.ListView.Items.IndexOf(targetVisualItem.Data);<br>
                if (insertIndex > -1)<br>
                {<br>
                    targetCell.Row.ListView.Items.Insert(insertIndex, item);<br>
                }<br>
            }<br>
            item["key_socRabotnik"] = draggedDataBoundItem["key_socRabotnik"];<br>
            item["[ФИО]"] = draggedDataBoundItem["[ФИО]"];<br>
<br>
            gridViewDataTable.Rows.Remove(draggedDataBoundItem);<br>
        }<br>
<br>
        private void PreviewDragOver(object sender, RadDragOverEventArgs e)<br>
        {<br>
            e.CanDrop = e.HitTarget is GridTableElement ||<br>
                e.HitTarget is GridDataRowElement;<br>
        }<br>
<br>
        private void PreviewDragDrop(object sender, RadDropEventArgs e)<br>
        {<br>
            BaseListViewVisualItem draggedItem = e.DragInstance as BaseListViewVisualItem;<br>
            GridDataRowElement rowElement = e.HitTarget as GridDataRowElement;<br>
            GridTableElement tableElement = e.HitTarget as GridTableElement;<br>
<br>
            if (rowElement == null && tableElement == null)<br>
            {<br>
                return;<br>
            }<br>
            e.Handled = true;<br>
            DataRow newRow = gridViewDataTable.NewRow();<br>
            newRow["key_socRabotnik"] = draggedItem.Data["key_socRabotnik"];<br>
            newRow["[ФИО]"] = draggedItem.Data["[ФИО]"];<br>
            if (tableElement != null)<br>
            {<br>
                gridViewDataTable.Rows.Add(newRow);<br>
            }<br>
            <br>
            if (rowElement != null)<br>
            {<br>
                GridViewRowInfo targetRow = rowElement.RowInfo;<br>
<br>
                int insertIndex = this.radGridView2.Rows.IndexOf(targetRow);<br>
                if (insertIndex > -1)<br>
                {<br>
                    gridViewDataTable.Rows.InsertAt(newRow, insertIndex);<br>
                }<br>
            }<br>
            <br>
<br>
            this.radListView1.Items.Remove(draggedItem.Data);<br>
        }</p> <p><br></p> <p>private void fillTheDataGrid()<br>
        {<br>
            var commandServer = new CommandServer();<br>
            try<br>
            {<br>
                radGridView2.Invoke(new MethodInvoker(delegate ()<br>
                {<br>
                    _bindingSource = new BindingSource { DataSource = commandServer.GetDataGridSet(@"select key_socRabotnik, fio as [ФИО]<br>
                        from socRabotnik<br>
                        where statusDel = 0<br>
                        order by fio").Tables[0] };<br>
                    radGridView2.DataSource = _bindingSource;<br>
<br>
                    if (radGridView2.Columns.Count > 0)<br>
                    {<br>
                        radGridView2.Columns[0].IsVisible = false;<br>
                        radGridView2.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;<br>
                    }<br>
                    <br>
                    _bindingSource = new BindingSource { DataSource = commandServer.GetDataGridSet(@"select key_socRabotnik, fio as [ФИО]<br>
                        from socRabotnik left join spec_soc on key_socRabotnik = fk_socRabotnik<br>
                        where fk_socRabotnik is null").Tables[0] };<br>
                    radListView1.DataSource = _bindingSource;<br>
                    radListView1.DisplayMember = "[ФИО]";<br>
                    radListView1.ValueMember = "[ФИО]";<br>
                    radListView1.Columns[0].Visible = false;<br>
                }));<br>
            }<br>
            catch (Exception ex)<br>
            {<br>
                CommandClient commandClient = new CommandClient();<br>
                commandClient.WriteFileError(ex, null);<br>
            }<br>
        }</p>

 

ListView to GridView: It is dragged, deleted, but not in the grid.

GridView to ListView: error image
Dimitar
Telerik team
 answered on 04 Dec 2017
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
Styling
Barcode
BindingNavigator
PopupEditor
RibbonForm
TaskBoard
Callout
ColorBox
PictureBox
FilterView
NavigationView
Accessibility
VirtualKeyboard
DataLayout
Licensing
ToastNotificationManager
ValidationProvider
CalculatorDropDown
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
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?