Telerik Forums
UI for WinForms Forum
3 answers
166 views

Hello, I'm using Openedge 11.6. How do I go about capturing the selected item in a RadListbox and display it in another field? There is only 1 column and the details in the List are programmatically loaded. What I have below is displaying the Listbox object and not the selected items.

 

@VisualDesigner.
method private void radListView1_Click( input sender as System.Object, input e as System.EventArgs ):
    this-object:radtextbox2:text = cast(sender, Telerik.WinControls.UI.RadListView):text.
     return.
end method.

 

Also, is there a resource available with sample code for Openedge Visual Designer developers?

Thanks

Mark

Dimitar
Telerik team
 answered on 25 Nov 2016
7 answers
389 views


Hi

I have been frustrated about this.. What I need is simple – Need to know the visible ranges of both X & Y axis. I am using a Range Selector, but it seems only to give me X ranges. I need Y too. (Also using a LassoZoomController) I have not been able to find anything. Please help.

Thanks
Hristo
Telerik team
 answered on 24 Nov 2016
6 answers
337 views

Hello,

I need some help with my application code.

I'm trying to do a PerformClick on a CommandColumn in a single row in a single cell.

How can I access the ButtonElement in that cell and do a PerformClick event programmatically?

Thanks in advance

Roberto

Roberto Wenzel
Top achievements
Rank 2
 answered on 24 Nov 2016
7 answers
224 views

Hi, 

When this mode is set and new screen location point is applied, then the window shrinks in height each time it's shown.
Even from 1-st ShowDialog its width becomes less.

Example:
If it's used as the once instatiated dialogBox and is shown each time it is needed, then each showtime it becomes less and less in heigth, up to its Top bar.

 

 

Dimitar
Telerik team
 answered on 24 Nov 2016
4 answers
892 views

I use the following function to load Horse names starting with a given letter

The first call returns and displays the list in the grid view

But at the second and following calls, while the HorseList is correctly generated, the display in the grid does not display the new list

I know that this questionhas been discussed many times but I have not found the solution .....

Thanks in advance

-----------------------------------------------------------------------------------------------------------------------------------------------------------------

      Public Function LoadNode(ByVal FirstLetter As String) As Boolean
        Try
            Dim aHorse As New mHorse
            Dim Horses As New List(Of Horse)
            'Load the Horses list where the name starts with "FirstLetter"
            Horses = aHorse.LoadNode(FirstLetter)
            If Horses.Count > 0 Then
                gvHorse.BeginUpdate()
                gvHorse.DataSource = Horses
                gvHorse.EndUpdate()
            Else

            End If
        Catch ex As Exception

        End Try
    End Function

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 24 Nov 2016
4 answers
291 views

I can't figure out how to do the following 2 things.

1. Set the width of the exported columns. They look ok in my grid in the WinForm, but when exported take up too much space.

2. How do I change the style of the column headers? I would like to bold it.

Here's my code.

private void btnExportVendorInvoices_Click(object sender, EventArgs e)
{
    using (SaveFileDialog dialog = new SaveFileDialog())
    {
        dialog.Filter = "Microsoft Excel (*.xlsx)|*.xlsx";
        dialog.FilterIndex = 2;
        dialog.RestoreDirectory = true;
 
        if (dialog.ShowDialog() == DialogResult.OK)
        {
 
            rgvInvoices.EnableAlternatingRowColor = true;
            var exporter = new ExportToExcelML(rgvInvoices);
            exporter.SheetMaxRows = ExcelMaxRows._1048576;
            exporter.HiddenColumnOption = HiddenOption.DoNotExport;
            exporter.ExportVisualSettings = true;
            exporter.ExcelCellFormatting += explorter_ExcelCellFormatting;
            exporter.RunExport(dialog.FileName);
            exporter.ExcelRowFormatting += exporter_ExcelRowFormatting;
 
            var dr = RadMessageBox.Show(this, "File has been saved, would you like to open it?",
                                        "File saved", MessageBoxButtons.YesNo, RadMessageIcon.Info);
            if (dr.ToString() == "Yes")
            {
                System.Diagnostics.Process.Start(dialog.FileName);
            }
        }
    }
}
 
 
private void explorter_ExcelCellFormatting(object sender, ExcelCellFormattingEventArgs e)
{
    if (e.GridCellInfo.RowInfo is GridViewDataRowInfo)
    {
        if (e.GridCellInfo.ColumnInfo.Name == "vendorFedId")
        {
            e.ExcelCellElement.Data.DataItem = string.Format("{0:00-0000000}", Convert.ToInt32(e.GridCellInfo.Value));
        }
    }
}
Dimitar
Telerik team
 answered on 24 Nov 2016
7 answers
140 views

Hi all,
i have a problem with a pivotgrid, as the title say i would like to add some filter conditions to my grid, below some lines of my code:

 

 this.radPivotGrid1.DataSource = LINQToDataTable(query);
            this.radPivotFieldList1.AssociatedPivotGrid = this.radPivotGrid1;

            this.radPivotGrid1.RowGroupDescriptions.Add(new PropertyGroupDescription() { PropertyName = "STATUS", GroupComparer = new GrandTotalComparer() });
            this.radPivotGrid1.ColumnGroupDescriptions.Add(new PropertyGroupDescription() { PropertyName = "SOMETHING", GroupComparer = new GrandTotalComparer() });
            this.radPivotGrid1.AggregateDescriptions.Add(new PropertyAggregateDescription() { PropertyName = "SOMETHING_ELSE", AggregateFunction = AggregateFunctions.Count });


            this.radPivotGrid1.AllowGroupFiltering = true;

            PropertyGroupDescriptionBase description = (PropertyGroupDescriptionBase)this.radPivotGrid1.RowGroupDescriptions[0];  //STATUS
            LabelGroupFilter filter = new LabelGroupFilter();
            TextCondition condition = new TextCondition();

            condition.Comparison = Telerik.Pivot.Core.Filtering.TextComparison.DoesNotContain;
            condition.Pattern = "SELLED";     <-------------- here i would like to insert more than one condition
            filter.Condition = condition;
            description.GroupFilter = filter;

as you can read in the comment i would like to say, for example: "Display only if my STATUS is not "SELLED" or "LOST"

There is a way to do it?

thank you very much

 

Andrea

Dimitar
Telerik team
 answered on 24 Nov 2016
9 answers
2.6K+ views

Hi,

Inthat scenario, when I try to edit the selected item, you'll see thelist.Selected Value is not changed.
But if you press button to get the Selected Value, you'll it's already = null.

It should keep the selected value, because it's needed to update data (text), using the id as value in a DB table..

public partial class RadForm2 : Telerik.WinControls.UI.RadForm
{
     
    RadDropDownList list = new RadDropDownList();
    TextBox tb = new TextBox();
    Button b = new Button();
 
    public RadForm2()
    {
        InitializeComponent();
        this.Controls.AddRange(new Control[] { list, tb, b });
 
        list.DropDownStyle = RadDropDownStyle.DropDown;
        list.Location = new Point(30, 30);
        list.Width = 100;
        list.Height = 25;
        list.DisplayMember = "name";
        list.ValueMember = "id";
        list.NullText = "not selected";
        list.SelectedValueChanged += list_SelectedValueChanged;
 
        tb.Location = new Point(30, 70);
        tb.Width = 100;
        tb.Height = 25;
 
        DataTable dt = new DataTable();
        dt.Columns.Add("id", typeof(int));
        dt.Columns.Add("name", typeof(string));
 
        dt.Rows.Add(1, "one");
        dt.Rows.Add(2, "two");
        dt.Rows.Add(3, "three");
        dt.Rows.Add(4, "four");
        dt.Rows.Add(5, "five");
        list.DataSource = dt;
 
        b.Location = new Point(30, 110);
        b.Width = 100;
        b.Height = 25;
        b.Text = "Get Selected Value";
        b.Click += b_Click;
    }
 
    void b_Click(object sender, EventArgs e)
    {
        tb.Text = list.SelectedValue + " <----> " + list.SelectedText;
    }
 
    void list_SelectedValueChanged(object sender, EventArgs e)
    {
        tb.Text = list.SelectedValue + " <----> " + list.SelectedText;
    }
}

 

Роберт
Top achievements
Rank 1
 answered on 23 Nov 2016
1 answer
174 views
We are interested in upgrading to the latest version of UI. Can we use the version of UI alongside an older version?

We are currently using UI for Winforms version 2011.2.11.0712.

Can we gradually upgrade our programs by including controls from the new version without interfering with controls using the older version?
Dimitar
Telerik team
 answered on 23 Nov 2016
4 answers
150 views

Is there any way to attach a picture before text of any any column ?

Regards

MSA

Dimitar
Telerik team
 answered on 23 Nov 2016
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?