Telerik Forums
UI for WinForms Forum
2 answers
300 views

I have a control that is derived from RadLabel. Inside this control I would like to add a RadContext menu instead of the standard Windows Forms context menu. What's the proper way to do this inside my control? I don't want to rely on a ContextMenuManager on the parent form but instead encapsulate everything in my control.

Regards

Erwin

erwin
Top achievements
Rank 1
Veteran
Iron
 answered on 24 Sep 2016
6 answers
1.1K+ views
I have a Commandbar with a stripelement that is stretched horizontaly across my form. I would like to add a label and a button and have the label aligned to the left and the button aligned to the right side of the Command bar. How can I accomplish this?
Thanks.
Craig
Top achievements
Rank 2
 answered on 23 Sep 2016
3 answers
159 views

     I have a c# aplication where I have to build programaticly many RadImageButtonElements from scratch. When I move the mouse over the RadImageButtonElement the button doesn't highlight if I hover with the mouse over the button. When I add a new RadImageButtonElement from RadRibbonBar when I hover over with the mouse I see that the RadImageButtonElement will be highlighted. Can you please help me what to add to my my code so that my RadImageButtonElement can be highlighted as well. Thank you for your time and if it is not the correct forum please move this thread to the correct forum.

           At RadRibbonBar you can add an RadImageButtonElement through the Edit Items functionality. I have to create a new RadImageButtonElement programmability and cannot make the item highlighted when my mouse hovers over the RadImageButtonElement. When I add an RadImageButtonElement through Edit Items functionality then I can highlight the RadImageButtonElement when I hover with my mouse over the ribbonbar element.

I added the code:

  RadImageButtonElement oButton = new RadImageButtonElement();

  // add image to the button and other things

  oButton.Text = oOperation.ToString();

  oButton.DisplayStyle = DisplayStyle.ImageAndText;
oButton.TextImageRelation = TextImageRelation.ImageAboveText;
oButton.Image = oButton.ImageClicked = oButton.ImageHovered = GetButtonImage(oOperation, true);

  rrbgOptions.Items.Add(oButton);

rrbgOptions is the form RadRibbonBarGroup .  When I run my program inside the RadRibbonBarGroup the image buttons created with the RadImageButtonElement apears but when I move my mouse over the buttons they don't highlight. 

When I add the Image button on using the form RadRibbonBarGroup Edit Items controls to create the Image buttons the buttons will be highlighted when I move my mouse over them.

Can you  please help so that the Image Buttons created programaticly as shown as above can be highlighted when I move the mouse over them.

Thank you.

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 23 Sep 2016
1 answer
122 views

Hello!!

How I can sort the series of chart? Check the attachments. For your help thanks.

Hristo
Telerik team
 answered on 22 Sep 2016
2 answers
143 views

Hi,

I am trying to snap the coloring of area series around to horizontal axis. The first pic (Area Coloring) illustrates what I've got, Area Color Goal what I'd like to see. I've already tried to split negative values from positives, like this http://www.telerik.com/forums/set-the-color-of-negative-value-on-areaseries, but the result is the same in winforms.

Please advise.

Best Regards.

Christian
Top achievements
Rank 1
 answered on 22 Sep 2016
1 answer
541 views

hi

i use rich text editor with ribbon ui and have several questions

1. i have a rich text editors with ribbon ui. how can customize the ribbon groups that show my desired element. for example i dont want bullets group.

2. in code block example in win forms rich text editor, the RadItem is create and added to home tab but there is no click event that show the code block is executed.

3. i have an executable file that i want execute in insert tab. how can i do that?

4.how can i subscribe a method to execute when user click symbol instead of default action.

thanks you

Hristo
Telerik team
 answered on 21 Sep 2016
1 answer
132 views

Hello Support,

  I am using Telerik for Winforms version 2015.2.728.40.  We are testing our application using Remote Desktop Services in Windows Server 2012.  We are experiencing an issue with all the drop downs in that the drop down window does not consistently show. Most times, the display window for the drop down lists are truncated, even though the items are still selectable.

I created a sample application with one form and one dropdownlist and was able to reproduce this behavior with Telerik version 2015.2.728.40.

I updated the sample to version 2016.2.608.40 and only saw the issue once.

I'm wondering if there is anything I can do to make the dropdownlist list show correctly with version 2015.2.728.40?

 

Thanks

Francisco

Hristo
Telerik team
 answered on 21 Sep 2016
2 answers
849 views

Hi all,

Can I format a cell value with underline in textbox column of a 

According to this link, http://docs.telerik.com/devtools/winforms/gridview/cells/formatting-cells, only 4 style properties can be set:

Fill
Border
Font
ForeColor

Best,

Tri Nguyen

 

Cao Trí
Top achievements
Rank 1
 answered on 21 Sep 2016
3 answers
273 views
Is there a way that you can allow people to use this text box to either enter feet and inches or just inches for their height and get the value just in inches?
Hristo
Telerik team
 answered on 20 Sep 2016
1 answer
138 views

I tried to use GridView in Master/Details Mode to get data from MongoDb Server.

And as the pic shows, I get the Id and the name from a Collection of Users, then I Iterate the parent Rows to get the Id and I fetch in the 2nd Colection of Product to get the details of each user.

In the server, the 1st user have only 1 product but in the pic it show it 3 times with 2 tables.

So how to get the right results and how work with Master/Detail GridView

namespace TelerikGridView
{
    public partial class Form2 : Form
    {
        List<WatchTblCls> wts;
        List<UserCls> user;
        List<SymboleCls> symb;
        public Form2()
        {
            InitializeComponent();
            wts = new List<WatchTblCls>();
            user = new List<UserCls>();
            symb = new List<SymboleCls>();
        }
 
        private async void button1_Click(object sender, EventArgs e)
        {
            // add user into datagridview from MongoDB Colelction Watchtbl
            var client = new MongoClient("mongodb://servername:27017");
 
            var database = client.GetDatabase("WatchTblDB");
            var collectionWatchtbl = database.GetCollection<BsonDocument>("Watchtbl");
            var collectionUser = database.GetCollection<BsonDocument>("Users");
 
            //wts = await collectionWatchtbl.Find(x => true).ToListAsync();
 
            //Get User Data
            var filter = new BsonDocument();
            using (var cursor = await collectionUser.FindAsync(filter))
            {
                while (await cursor.MoveNextAsync())
                {
                    var batch = cursor.Current;
                    foreach (var document in batch)
                    {
                        user.Add(new UserCls()
                        {
                            Id = ObjectId.Parse(document["_id"].ToString()),
                            Name = document["Name"].ToString()
                        });
                    }
                }
            }
 
            //Get WatchTbl Data
            using (var cursor = await collectionWatchtbl.FindAsync(filter))
            {
                while (await cursor.MoveNextAsync())
                {
                    var batch = cursor.Current;
                    foreach (var document in batch)
                    {
                        wts.Add(new WatchTblCls()
                        {
                            Id = ObjectId.Parse(document["_id"].ToString()),
                            UserId = document["userId"].ToString(),
                            WID = document["wid"].ToString(),
                            Name = document["name"].ToString()
                            //Symbole
                        });
                    }
                }
            }
 
            this.radGridView1.DataSource = user;
            this.radGridView1.Columns["fbId"].IsVisible = false;
            this.radGridView1.Columns["Pass"].IsVisible = false;
        }
 
        GridViewTemplate childTemplate;
        private GridViewTemplate CreateChildTemplate()
        {
            childTemplate = new GridViewTemplate();
            this.radGridView1.Templates.Add(childTemplate);
            GridViewTextBoxColumn column = new GridViewTextBoxColumn("wid");
            childTemplate.Columns.Add(column);
 
            column = new GridViewTextBoxColumn("name");
            childTemplate.Columns.Add(column);
 
            childTemplate.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;
            return childTemplate;
        }
 
        private void Form2_Load(object sender, EventArgs e)
        {
            GridViewTemplate childTemplate = CreateChildTemplate();
            this.radGridView1.Templates.Add(childTemplate);
            childTemplate.HierarchyDataProvider = new GridViewEventDataProvider(childTemplate);
 
        }
 
        private void radGridView1_RowSourceNeeded(object sender, GridViewRowSourceNeededEventArgs e)
        {
            foreach (GridViewRowInfo item in radGridView1.Rows)
            {
                var itll = item.Cells["id"].Value.ToString();
                foreach (var itemWts in wts)
                {
                    if (itll == itemWts.UserId.ToString())
                    {
                        GridViewRowInfo row = e.Template.Rows.NewRow();
                        row.Cells["wid"].Value = itemWts.WID.ToString();
                        row.Cells["name"].Value = itemWts.Name.ToString();
                        //symbole
                        e.SourceCollection.Add(row);
                    }
                }
            }
        }
    }
 
    public class WatchTblCls
    {
        [BsonId]
        public ObjectId Id { get; set; }
        public string UserId { get; set; }
        public string WID { get; set; }
        public string Name { get; set; }
        public List<SymboleCls> Symbols { get; set; }
 
         
    }
 
    public class UserCls
    {
        [BsonId]
        public ObjectId Id { get; set; }
        public string fbId { get; set; }
        public string Name { get; set; }
        public string Pass { get; set; }
 
 
    }
 
    public class SymboleCls
    {
        [BsonId]
        public ObjectId Id { get; set; }
        public string Name { get; set; }
    }
}

Hristo
Telerik team
 answered on 20 Sep 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)
Form
Chart (obsolete as of Q1 2013)
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
VirtualGrid
Toolstrip (obsolete as of Q3 2010)
AutoCompleteBox
Label
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
SplitContainer
Documentation
Map
DesktopAlert
CheckedDropDownList
ProgressBar
MessageBox
TrackBar
Rotator
SpinEditor
CheckedListBox
StatusStrip
CollapsiblePanel
LayoutControl
ShapedForm
SyntaxEditor
Wizard
TextBoxControl
Conversational UI, Chat
DateTimePicker
TabbedForm
CAB Enabling Kit
WaitingBar
GroupBox
DataEntry
ScrollablePanel
ScrollBar
ImageEditor
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
FileDialogs
ColorDialog
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
NavigationView
BindingNavigator
RibbonForm
Styling
Barcode
PopupEditor
TaskBoard
Callout
ColorBox
PictureBox
FilterView
Accessibility
VirtualKeyboard
DataLayout
Licensing
ToastNotificationManager
ValidationProvider
CalculatorDropDown
Localization
TimePicker
BreadCrumb
ButtonTextBox
FontDropDownList
BarcodeView
Overlay
Security
LocalizationProvider
Dictionary
TreeMap
StepProgressBar
SplashScreen
Flyout
Separator
SparkLine
ToolbarForm
NotifyIcon
DateOnlyPicker
AI Coding Assistant
Rating
TimeSpanPicker
Calculator
OfficeNavigationBar
TaskbarButton
HeatMap
SlideView
PipsPager
AIPrompt
TaskDialog
TimeOnlyPicker
SpeechToTextButton
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?