Telerik Forums
UI for WinForms Forum
4 answers
175 views

I am having trouble removing the blank space between hierarchies / childviews when using the RadVirtualGrid to display hierarchical data.

(see Image01 attached)

If I set 

MasterViewInfo.Padding = new Padding(0);

and

e.ChildViewInfo.Padding = new Padding(0);

the situation improves (see Image02 attached), but I still can't seem to remove all of the spacing between childviews.

 

Any ideas?

 

Thanks,

Tom

Thomas
Top achievements
Rank 1
 answered on 02 May 2017
0 answers
104 views

Hello i wanna ask about this ... 

i have a button with this code 

   Private Sub BtnBaru_Click(sender As System.Object, e As System.EventArgs) Handles BtnBaru.Click

       xStatus = "NEW"

        MCCBRekening.Enabled = True
        Isi_MCCBRekening()

        TxtKodeSubRekening.Enabled = True
    End Sub

 

and procedure Isi_MCCBRekening 

   Private Sub Isi_MCCBRekening()
        Dim TblMstRekening As DataTable

        TblMstRekening = ds.Tables.Add("Rekening")
        With TblMstRekening
            .Columns.Add("Kode", GetType(String))
            .Columns.Add("Nama", GetType(String))
        End With

        Using conn As New OleDbConnection(str)
            conn.Open()

            da = New OleDbDataAdapter("SELECT KodeRekening as Kode, NamaRekening as Nama FROM MstRekening ORDER BY KodeRekening", conn)
            ds = New DataSet
            ds.Clear()
            TblMstRekening.Rows.Add(New Object() {"", ""})

            da.Fill(TblMstRekening)
            da.Dispose()

            conn.Close()
        End Using

        With MCCBRekening
            .MultiColumnComboBoxElement.DropDownWidth = 500
            .DataSource = TblMstRekening
            .BestFitColumns()

            .EditorControl.EnableCustomFiltering = True

            .SelectedValue = ""
            .AutoFilter = True

            .DisplayMember = "Kode"
            .ValueMember = "Kode"
            .Text = ""

            Dim filter As New FilterDescriptor()
            filter.PropertyName = Me.MCCBRekening.ValueMember
            filter.[Operator] = FilterOperator.Contains
            Me.MCCBRekening.EditorControl.MasterTemplate.FilterDescriptors.Add(filter)
            MCCBRekening.MultiColumnComboBoxElement.EditorControl.EnableCustomFiltering = True

            AddHandler .MultiColumnComboBoxElement.EditorControl.CustomFiltering, AddressOf MCCBRekening_CustomFiltering
            AddHandler .KeyDown, AddressOf MCCBRekening_KeyDown

        End With
    End Sub
    Private Sub MCCBRekening_CustomFiltering(ByVal sender As Object, ByVal e As Telerik.WinControls.UI.GridViewCustomFilteringEventArgs)

        Dim element As RadMultiColumnComboBoxElement = MCCBRekening.MultiColumnComboBoxElement

        Dim textToSearch As String = MCCBRekening.Text
        If AutoCompleteMode.Append = (element.AutoCompleteMode And AutoCompleteMode.Append) Then
            If element.SelectionLength > 0 AndAlso element.SelectionStart > 0 Then
                textToSearch = MCCBRekening.Text.Substring(0, element.SelectionStart)
            End If
        End If

        If String.IsNullOrEmpty(textToSearch) Then
            e.Visible = True

            For i As Integer = 0 To element.EditorControl.ColumnCount - 1
                e.Row.Cells(i).Style.Reset()

            Next

            e.Row.InvalidateRow()
            Return
        End If

        e.Visible = False
        For i As Integer = 0 To element.EditorControl.ColumnCount - 1
            Dim text As String = e.Row.Cells(i).Value.ToString()
            If text.IndexOf(textToSearch, 0, StringComparison.InvariantCultureIgnoreCase) >= 0 Then
                e.Visible = True
                e.Row.Cells(i).Style.CustomizeFill = True
                e.Row.Cells(i).Style.DrawFill = True
                e.Row.Cells(i).Style.BackColor = Color.FromArgb(201, 252, 254)
            Else
                e.Row.Cells(i).Style.Reset()

            End If
        Next
        e.Row.InvalidateRow()
    End Sub
    Private Sub MCCBRekening_KeyDown(ByVal sender As Object, ByVal e As KeyEventArgs) Handles MCCBRekening.KeyDown
        With MCCBRekening
            If e.KeyCode = System.Windows.Forms.Keys.Enter Then
                If .ValueMember <> "" Then
                    .SelectedValue = .EditorControl.CurrentRow.Cells(.ValueMember).Value
                Else
                    .SelectedValue = .EditorControl.CurrentRow.Cells(.DisplayMember).Value
                End If

                .Text = .EditorControl.CurrentRow.Cells(.DisplayMember).Value.ToString()
                .MultiColumnComboBoxElement.ClosePopup()
                .MultiColumnComboBoxElement.TextBoxElement.TextBoxItem.SelectAll()
            End If
        End With
    End Sub
    Private Sub MCCBRekening_DropDownClosed(ByVal sender As Object, ByVal args As Telerik.WinControls.UI.RadPopupClosedEventArgs) Handles MCCBRekening.DropDownClosed
        If MCCBRekening.SelectedIndex <> -1 Then
            lblNamaRekening.Text = MCCBRekening.EditorControl.Rows(MCCBRekening.SelectedIndex).Cells(1).Value.ToString
            TxtKodeRekening.Text = MCCBRekening.EditorControl.Rows(MCCBRekening.SelectedIndex).Cells(0).Value.ToString
        Else
            TxtKodeRekening.Text = ""
            lblNamaRekening.Text = ""
        End If
    End Sub
    Private Sub MCCBRekening_Validated(ByVal sender As Object, ByVal e As System.EventArgs) Handles MCCBRekening.Validated
        If MCCBRekening.Text = "" Then
            TxtKodeRekening.Text = ""
            lblNamaRekening.Text = ""
        End If
    End Sub

my question is :

why if i click the button for the second time it's give me error message ... the "Kode" is not belong to TblMstRekening .... 

 

how i  fix this thanks ... 

 

 

 

Hengky
Top achievements
Rank 1
Veteran
 asked on 02 May 2017
3 answers
261 views

Hello!

I was wondering if anyone knew of a simple algorithm to take a bunch of existing Lat/Lon points and calculate a rectangle out of them? I'm trying to have the map view center and zoom to fit a list of points automatically. I know how to center on one particular point but not sure how to do so for a group of points. I'm used to using the Google Maps API which has a function where you can keep adding geo points and it creates a bounding rectangle. Does RadMap have something similar to that?

Thanks! :)

Hristo
Telerik team
 answered on 02 May 2017
1 answer
263 views

Hi, i'm just tried telerik trial & newbie in telerik winform. I've read and looked up the documentation manual but i dont found flyout.
i want to question, how to create flyout for winform like my attach files:

thanks you.

:)

Hristo
Telerik team
 answered on 01 May 2017
4 answers
414 views

I have my own Grid Class based off of a RadGridView control, because I use the same formatting/settings in multiple places.  When I drag my grid to my form, everything seems fine, but when I add data to it, nothing is formatted.  The ROWS/COLUMNS have no formatting, no grid lines, etc. Not sure what I am doing wrong here.  Any help would be greatly appreciated. 

 

   public  class NtsRadGridView : RadGridView
   {
      #region Public Constructors
 
      public NtsRadGridView()
      {
         MasterTemplate.AllowAddNewRow = false;
         MasterTemplate.AllowCellContextMenu = false;
         MasterTemplate.AllowColumnChooser = false;
         MasterTemplate.AllowColumnHeaderContextMenu = false;
         MasterTemplate.AllowDeleteRow = false;
         MasterTemplate.AllowDragToGroup = false;
         MasterTemplate.AllowEditRow = false;
         MasterTemplate.AllowRowHeaderContextMenu = false;
         MasterTemplate.AllowRowResize = false;
         MasterTemplate.AllowSearchRow = true;
         MasterTemplate.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;
         MasterTemplate.ViewDefinition = new TableViewDefinition();
         ShowGroupPanel = false;
      }
}
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 01 May 2017
4 answers
318 views

Hi there.

Since today I'm trying to open my projected with telerik Win Controls, I'm trying to open my project. Microsoft Visual Studio 2013 Crashes..

same time i'm trying open other projects it opens without any problem

 

Microsoft Visual Studio has stopped working....

Can anyone help.. as my project is very important.

Rgds,

Stef
Telerik team
 answered on 28 Apr 2017
2 answers
134 views

Hi, 

I want to format the numbers of a list in a GridViewComboBoxColumn. The selected value is formatted correctly (Formatstring of the column is set to {0:N0}). But when the filter dialog is opened, the possible values are not formatted (no thousand seperators, 4 digits). How can I format these values? 

Thanks in advance, 

Andreas

Andreas
Top achievements
Rank 1
 answered on 28 Apr 2017
8 answers
724 views
Hi,

I have a RadGridView that has a checkbox column. When adding a new row (using AddNew method, if that matters), depending on some condition, I want to hide the checkbox of that row. It seemed simple enough, but I couldn't figure it out. Am I missing something obvious?

Please help. Thanks.

Andy
Hristo
Telerik team
 answered on 28 Apr 2017
19 answers
1.2K+ views
I'm new to winforms and telerik controls but I'm almost embarressed to write this. 

I'm using a GridView control in a basic winform application (.net 3.5) .  I'm using a  sql server database table datasource.    I set the gridview to AllowAddNewRow and AllowEditRow.  Very easily setup the app to view the data.  I'm able to insert and update records in the grid.  But those insert/updates are not committed to the database. 

I would appreciate any direction to help me learn how to simply add/update/delete records via the gridview.

Thanks!
Hristo
Telerik team
 answered on 28 Apr 2017
2 answers
94 views

Hello,

 

Is it possible to create a 'draggable' Pin.

I would like to drag a pin to a listbox to add it to a list of locations.

Hope you can help me.

Kind regards

Victor

Victor
Top achievements
Rank 2
 answered on 28 Apr 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?