Telerik Forums
UI for WinForms Forum
3 answers
186 views
Hi,

I use TSSP file that changes the appearance of the entire application.
There is a problem with the appearance when the user has different font scaling setting in Windows (120 DPI).
Due to the nature of the project I need to get the same appearance of the application, regardless of the DPI.
So using VisualStyleBuilder I changed the font size from the point value to the pixel value (Segoe UI; 8,25pt => Segoe UI; 11px).
In Annex, you can see the result.
Font has the same size. But the size of the control type CommandBarButton is strange. It looks as if I set the padding (but padding is 0 for all).
How to get rid of the padding?
For other types of controls do not see this behavior.
Dimitar
Telerik team
 answered on 12 Dec 2014
2 answers
157 views
Hi,

how can I set the left location of GanttViewGraphicalViewElement?

Thx
Frank
Top achievements
Rank 1
 answered on 11 Dec 2014
6 answers
306 views
I have a radSplitContainer where I would like to have a SplitterWidth of 3. Now, the background of everything in the project is black. The splitterarea is a greyshade, or silver. How do I change that to black?

Thanks,
Karl
Pierre
Top achievements
Rank 1
 answered on 11 Dec 2014
1 answer
95 views
tried to post it in Reporting forum, but unsuccessfully, doesn't show 

Hi,

here is the code for background printing.

        void ReportToDefault(Report report)
        {
            if (report == null) return;

            System.Drawing.Printing.PrintController standardPrintController =
                                    new System.Drawing.Printing.StandardPrintController();
            Telerik.Reporting.Processing.ReportProcessor reportProcessor
                                                = new Telerik.Reporting.Processing.ReportProcessor();
            reportProcessor.PrintController = standardPrintController;
            try
            {
                reportProcessor.PrintReport(report, Properties.Settings.Default.defaultPrinter);
            }
            catch (Exception ex) { MessageBox.Show(ex.Message); }
        }

The question is:

If the high intensive printing is needed, then what is the best practice to use the code? 
Is it better to instantiate the controller and processor only once, on the App start up, and then just pass arguments to PrintReport? 
What if it's using im multithreading mode, when Docs come ech time while the processor maybe is still busy in printing?
Thanks you!
Роберт
Top achievements
Rank 1
 answered on 10 Dec 2014
10 answers
362 views
Hi...

I've added a radtheme manager to my form loading themes from a file, but when i redistrubute my application, the path gets "hardcoded" to the project with my original folder path. Is there a way to reference to a project file or folder?

thanks
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 10 Dec 2014
3 answers
260 views
How do I pass RadScheduler_CellFormatting Telerik.WinControls.UI.SchedulerCellEventArgs in radSchedulerNavigator_NavigateForwardsClick?

  private void radSchedulerNavigator1_NavigateBackwardsClick(object sender, EventArgs e)
        {
           
            this.radCalendar1.FocusedDate = this.radScheduler1.ActiveView.StartDate;

            string  time_Nback1  = "";
            string time_Nback2 = "";

            if (radScheduler1.ActiveViewType == SchedulerViewType.Day)
            {
                SchedulerDayView dayView_ck = this.radScheduler1.GetDayView();
                time_Nback1 = dayView_ck.StartDate.ToString("yyyyMMdd");
                time_Nback2 = dayView_ck.EndDate.ToString("yyyyMMdd");
            }
            else if (radScheduler1.ActiveViewType == SchedulerViewType.Week)
            {
                SchedulerWeekView weekView_ck = this.radScheduler1.GetWeekView();
                time_Nback1 = weekView_ck.StartDate.ToString("yyyyMMdd");
                time_Nback2 = weekView_ck.EndDate.ToString("yyyyMMdd");
            }
            else if (radScheduler1.ActiveViewType == SchedulerViewType.Month)
            {
                SchedulerMonthView monthView_ck = this.radScheduler1.GetMonthView();
                time_Nback1 = monthView_ck.StartDate.ToString("yyyyMMdd");
                time_Nback2 = monthView_ck.EndDate.ToString("yyyyMMdd");
            }

            boundradschedulerview("001", time_Nback1, time_Nback2);
            dtHoilday = boundAppointmentObj.listDoctorOffTime("001", time_Nback1, time_Nback2);
            radScheduler1_CellFormatting(sender, (Telerik.WinControls.UI.SchedulerCellEventArgs) e);
        }

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 10 Dec 2014
1 answer
1.2K+ views
How I can loop through all row of my grid and detect only row with checkbox column checked ?
Hristo
Telerik team
 answered on 10 Dec 2014
2 answers
160 views
some of buttons disabled and another buttons are enabled depending on condition 
the problem is , if you sort the radgridview by clicking the header of data column these enabled buttons will be disabled and disabled buttons somtimes will be enabled , i tried ViewCellFormatting event but have the same problem.
You can see the attached screenshot before and after sorting ..
 private void grvDepartment_CellFormatting(object sender, CellFormattingEventArgs e)
        {            
            if (e.RowIndex > -1) // not header
            {
                var cellElement = e.CellElement;
                int departmentId = Convert.ToInt32(e.Row.Cells["DepartmentId"].Value);                
                ICollection<UserProfile> usersProfiles =
                     (from u in _outEntities.UserProfile.Local where u.DepartmentId == departmentId select u).ToList();

                if (usersProfiles.Count > 0)
                {
                    #region MyRegion
                    if (cellElement.ColumnInfo.Name == "DepartmentName")
                        cellElement.Enabled = false;
                    else if (cellElement.ColumnInfo.Name == "DepartmentAcronum")
                        cellElement.Enabled = false;
                    else cellElement.Enabled = true; 
                    #endregion

                    var cell = cellElement as GridCommandCellElement;
                    if (cell != null)
                    {
                        #region MyRegion
                        if (cell.ColumnInfo.Name == "colUpdate")
                            cell.Enabled = false;
                        //cell.Visibility = ElementVisibility.Hidden;
                        else if (cell.ColumnInfo.Name == "colDelete")
                            //cell.Visibility = ElementVisibility.Hidden; 
                            cell.Enabled = false;
                        else cell.Enabled = true;
                        //cell.Visibility = ElementVisibility.Visible;
                        #endregion
                    }
                }
            }            
        }



Omar
Top achievements
Rank 2
 answered on 10 Dec 2014
8 answers
314 views
Hi,

I encounter the problem like in subject. You can simply reproduce it by:
1) create simple project with RadGridView
2) Set model as ObjectDataSource
3) fill it like this:
  •  public Form1()
            {
                InitializeComponent();

                List<Model> model = GenerateModel();
                this.radGridView1.DataSource = model;
            }
  • private List<Model> GenerateModel()
            {
                List<Model> model = new List<Model>();

                // 1)    EVERYTHING WORKS FINE
                //for (int i = 0; i < 100000; i++)
                //{
                //    Model m = new Model() { Text = i.ToString(), Number = i, Text2 = i.ToString() };
                //    model.Add(m);
                //}

                // 2)    SLOW DOWN
                for (int i = 0; i < 100000; i++)
                {
                    Model m = new Model() { Text = i.ToString(), Number = i, Text2 = "1" };
                    model.Add(m);
                }

                return model;
            }
  • public class Model
        {
            public string Text { get; set; }
            public int Number { get; set; }
            public string Text2 { get; set; }
        }

When you uncoment version one ( and of course comment version 2 ) everything works fine = selecting rows / cells works perfect.
But when you comment version 1 and uncoment second ( like in above example ) after set sorting on third column ( Text2 ) selecting rows / cells slows down. When you clear sorting on third column behavior back to normal. Sorting by another columns ( first or second ) doesn't couse such behavior.
So in my opinion it is happend when many cells in sorted columns contain the same value.
I think that because when fill only half of rows with the same value and rest with different it spead up.

Does someone has any solution for this
Thanks in advance
Ivan Todorov
Telerik team
 answered on 09 Dec 2014
7 answers
200 views
Dear All,

I'm facing a problem in using RadContextMenu, my form contains three charts and i want to assign the same menu for all of them so i used The RadContextMenu property to assign the menu, but my problem is when the user pick any choice from the menu, how can i know on which chart did the user click ?? the sender contains rad menu control not the chart control.

Thank you
Peter
Telerik team
 answered on 08 Dec 2014
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?