Telerik Forums
UI for WinForms Forum
1 answer
48 views

Below is the code i am using for visualitemcreating, however the layout is not coming out proper, can anyone please help me with this.

When i run the code, i am getting the listview as  which does not include the role and email details that should com in the second row.

Please help, i am unable to find what i am missing here.

Public Class CustomUserVisualItem
    Inherits SimpleListViewVisualItem
    Private Row1Element As LightVisualElement
    Private Row2RoleElement As LightVisualElement
    Private Row2EMailElement As LightVisualElement
    Private stackLayoutMain As StackLayoutPanel
    Private stackLayoutRow2 As StackLayoutPanel
    Protected Overrides Sub CreateChildElements()
        MyBase.CreateChildElements()
        Me.stackLayoutMain = New StackLayoutPanel()
        Me.stackLayoutMain.Orientation = Orientation.Vertical
        Me.stackLayoutMain.EqualChildrenWidth = True
        Me.stackLayoutMain.ShouldHandleMouseInput = False
        Me.stackLayoutMain.NotifyParentOnMouseInput = True
        Me.Children.Add(Me.stackLayoutMain)

        Me.Row1Element = New LightVisualElement()
        Me.Row1Element.StretchHorizontally = True
        Me.Row1Element.MinSize = New Size(120, 0)
        Me.Row1Element.ShouldHandleMouseInput = False
        Me.Row1Element.NotifyParentOnMouseInput = True
        Me.stackLayoutMain.Children.Add(Me.Row1Element)


        Me.stackLayoutRow2 = New StackLayoutPanel()
        Me.stackLayoutRow2.Orientation = Orientation.Horizontal
        Me.stackLayoutRow2.EqualChildrenWidth = True
        Me.stackLayoutRow2.ShouldHandleMouseInput = False
        Me.stackLayoutRow2.NotifyParentOnMouseInput = True
        Me.stackLayoutMain.Children.Add(Me.stackLayoutRow2)

        Me.Row2EMailElement = New LightVisualElement()
        Me.Row2EMailElement.Text = "Email"
        Me.Row2EMailElement.MinSize = New Size(60, 0)
        Me.Row2EMailElement.TextAlignment = ContentAlignment.MiddleLeft
        Me.Row2EMailElement.NotifyParentOnMouseInput = True
        Me.Row2EMailElement.ShouldHandleMouseInput = False
        Me.stackLayoutRow2.Children.Add(Me.Row2EMailElement)

        Me.Row2RoleElement = New LightVisualElement()
        Me.Row2RoleElement.Text = "Role"
        Me.Row2RoleElement.MinSize = New Size(60, 0)
        Me.Row2RoleElement.TextAlignment = ContentAlignment.MiddleRight
        Me.Row2RoleElement.NotifyParentOnMouseInput = True
        Me.Row2RoleElement.ShouldHandleMouseInput = False
        Me.stackLayoutRow2.Children.Add(Me.Row2RoleElement)


    End Sub
    Protected Overrides Sub SynchronizeProperties()
        MyBase.SynchronizeProperties()

        Dim product As UsersList = TryCast(Me.Data.Tag, UsersList)
        Dim color As String = ""

        If product.userstatus = "Active" Then
            color = "Green"
        Else
            color = "Red"
        End If

        Me.Text = ""
        Me.Row1Element.Text = "<html><span style=""color: " & color & "; font-size: 12pt;"">• </span> <span style=""font-size:12pt;"">" & product.firstName & " " & product.lastName & "</span>"
        Me.Row2RoleElement.Text = "<html><span style=""font-size:9pt;"">" & product.role & "</span>"
        Me.Row2EMailElement.Text = "<html><span style=""font-size:9pt;"">" & product.email & "</span>"
    End Sub
    Protected Overrides ReadOnly Property ThemeEffectiveType() As Type
        Get
            Return GetType(SimpleListViewVisualItem)
        End Get
    End Property
End Class

Nadya | Tech Support Engineer
Telerik team
 answered on 04 Sep 2024
1 answer
68 views

We have incomming PDF documents that have been annotated/marked up/stamped (we beleive using Adobe). When you view or print from Telerik the "annotations" are missing or wrongly formated. 

Chrome and Edge both display the PDF correctly.

Are there any properties or techniques I can use to get Telerik PDF to include the annotations ?

Attached are the original PDF "PDFMarkUp.pdf" and the PDF as printed by Telerik "PDFMarkUpOUT.pdf" (Replicates the Telerik View )

Nadya | Tech Support Engineer
Telerik team
 answered on 03 Sep 2024
1 answer
61 views

I have a situation where I would like to customize the list of items provided by the auto-completion suggestion list in a RadCheckedDropDownList.  i.e. Even though radCheckedDropDownList1.DataSource is set to one list of values, I need to set radCheckedDropDownList1.AutoCompleteDataSource to a different list of values.  Whenever I attempt to do this, the auto-complete drop-down list still shows suggestions from the DataSource collection rather than the AutoCompleteDataSource collection.

If I attempt the same thing with a normal RadDropDownList, it works fine.  Is this functionality not supported with a RadCheckedDropDownList?  If not, why have an AutoCompleteDataSource property?  If it is supported, what is the proper usage to get it work?

Thanks!

--Darren

Nadya | Tech Support Engineer
Telerik team
 answered on 02 Sep 2024
1 answer
56 views

Hi everyone,

Does anyone know how to change the position of the "Add New Row" and the "Custom Filtering Row"?

Currently, the standard layout is as shown in the image below. I'd like to position the "Custom Filtering Row" just below the header and the "Add New Row" below the "Custom Filtering Row."

Nadya | Tech Support Engineer
Telerik team
 answered on 30 Aug 2024
1 answer
112 views

Hello,

Visual Studio 2022 is still crashing in some situations like form renaming, saving assembly information or refactoring. In revision notes for main Telerik extensions, I can see some crashes were fixed in 2024.3.808 version. But it's still crashing, but in WinForms Converter extension, last version is 2024.3.805, and I don't see any update. I have disabled that extension for now, I am not using it, so it's not a problem for me. Will you update also this extension?

Vesko
Telerik team
 answered on 30 Aug 2024
1 answer
80 views

 Hi,
    I want to remove or hide the Add or Remove Buttons / Customize... menu only. If i set like  this CommandBarStripElement4.OverflowButton.Visibility = Telerik.WinControls.ElementVisibility.Collapsed then whole overflow button will hide when i resize the screen to small. 
   I want to remove to hide only this two things Add or Remove Buttons / Customize...  from OverflowButton.

 

Thanks and Regards
Aravind

Nadya | Tech Support Engineer
Telerik team
 answered on 28 Aug 2024
1 answer
55 views

I have a MaskedEditBox called mtbText bound to a string property like this:

mtbText.DataBindings.Add(nameof(mtbText.Value), customerSearch, nameof(customerSearch.Text), false, DataSourceUpdateMode.OnPropertyChanged);

        public string? Text
        {
            get => _text;
            set
            {
                if (_text != value)
                {
                    _text = value;
                    OnPropertyChanged(nameof(Text));
                }
            }
        }

Sometimes I need a specific mask like SSN or phone # and sometimes I don't.  The UI resets the properties on the single mask control depending on need. If I bind to a specific mask like this (say a SSN or phone #) it works fine. However sometimes I need a mask that will allow anything. I tried aaaaaaaaaa and a few other combination but these won't let me enter blank spaces.  If I set the MaskType to None it allow the spaces but doesn't bind to the property.

mtbText.Mask = string.IsNullOrEmpty(item.Mask) ? "aaaaaaaaaa" : item.Mask; 

mtbText.MaskType = MaskType.Standard;

mtbText.TextMaskFormat = MaskFormat.ExcludePromptAndLiterals;

What mask can I use that would allow me to enter something like 123 Main Street and still bind to the object property.

Thanks

Carl

 

Dinko | Tech Support Engineer
Telerik team
 answered on 28 Aug 2024
1 answer
38 views

Hi Telerik support team,

I got into problems with a gridview. It seems that the grid losses focus and directly gets focus back. This happens every 1 or 2 seconds. I’ve created a small application with a simple grid with datasource and handlers for the Got- and LostFocus. Add a breakpoint on it and it will hit constantly.

My problem gets bigger because the datasource also gets kind of refreshed. In the sample application I’ve a class Person. Put there a breakpoint on the Name getter and every second or 2 it will hit.

Start the application, don’t click around, just wait. The breakpoints will hit.

What’s happening with the focus on the grid?? Why is it getting ‘stolen’? Can I prevent this behavior?

In the sample application look into the FocusIssueForm.

Regards,

Daniel

Nadya | Tech Support Engineer
Telerik team
 answered on 27 Aug 2024
1 answer
55 views

Hi,

I have an RadDropDownList filled with some record of a table (ttSoc) using DataSource and bounded functionality.

I have a button that lets me add/delete records from this table (ttsoc).
Impossible to update the RadDropDownList

 

my code:

in the form load I run ChargeCodeSociete('InitBe').

In the click button  I run ChargeCodeSociete('affiche').

METHOD PRIVATE VOID BtnSociete_Click( INPUT sender AS System.Object, INPUT e AS System.EventArgs ):

// On instancie la classe
        oFrmSociete = NEW frmSociete().
        // En attente du retour de la form en mode dialog box
        WAIT-FOR oFrmSociete:ShowDialog().

oongDescriptionEtudeGeneral:ChargeCodeSociete('Affiche').

RETURN.

END METHOD.

 

IN oongDescriptionEtudeGenral FORM

METHOD PUBLIC VOID ChargeCodeSociete( INPUT ipcMode AS CHARACTER ):
        CASE ipcMode:
            WHEN 'InitBe' THEN DO:
                beSociete= NEW fichier.description_etude.be.beSociete().

                beSociete:ReadbeSociete(OUTPUT DATASET dsSoc).

                //Associer le query du dataset au probadingSource
                bsSociete:HANDLE = DATASET dsSoc:HANDLE.
            END.
            WHEN 'Affiche' THEN DO:
                DATASET dsSoc:TOP-NAV-QUERY():QUERY-PREPARE("FOR EACH ttSoc").
                DATASET dsSoc:TOP-NAV-QUERY():QUERY-OPEN().   


                DropDownListCodeSociete: ?????

            END.
        END CASE.

 

thank you for your feedback

                                                                                              
Dinko | Tech Support Engineer
Telerik team
 answered on 26 Aug 2024
4 answers
47 views

Hello everyone, I have successfully changed the scroll bar color of the RadRichTextEditor control. However, no matter how I try to set and modify the color of the button on the scrollbar, it remains white. How can I achieve this? Thank you.

Kevin
Top achievements
Rank 2
Iron
Iron
 updated answer on 22 Aug 2024
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
Diagram, DiagramRibbonBar, DiagramToolBox
GanttView
Panorama
New Product Suggestions
Toolstrip (obsolete as of Q3 2010)
VirtualGrid
AutoCompleteBox
Label
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
Documentation
SplitContainer
Map
DesktopAlert
ProgressBar
CheckedDropDownList
TrackBar
MessageBox
Rotator
SpinEditor
StatusStrip
CheckedListBox
LayoutControl
SyntaxEditor
Wizard
ShapedForm
TextBoxControl
DateTimePicker
CollapsiblePanel
Conversational UI, Chat
TabbedForm
CAB Enabling Kit
GroupBox
DataEntry
ScrollablePanel
ScrollBar
WaitingBar
ImageEditor
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
ColorDialog
FileDialogs
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
BindingNavigator
PopupEditor
RibbonForm
Styling
TaskBoard
Barcode
Callout
ColorBox
PictureBox
FilterView
Accessibility
VirtualKeyboard
NavigationView
DataLayout
ToastNotificationManager
ValidationProvider
CalculatorDropDown
Localization
TimePicker
ButtonTextBox
FontDropDownList
Licensing
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
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?