Telerik Forums
UI for WinForms Forum
1 answer
268 views
I'm not understanding why it fails to update in another thread correctly if the process is running fast. Example

If I do this, this will freeze the progress bar until its completed. It will get to a certain spot then stop.
radProgressBar2.Maximum = 1500;
for (var i = 1; i < 1500; i++)
{
    var p = i;
    radProgressBar2.Value1 = p;
    Thread.Sleep((int)numericUpDown1.Value);
}
radProgressBar2.Value1 = 0;
radProgressBar2.Text = "Task Completed!";


If i do this 

radProgressBar1.Maximum = 1500;
for (var i = 1; i < 1500; i++)
{
    var p = i;
    radProgressBar1.SafeInvoke(() => radProgressBar1.Value1 = p, false);
    Thread.Sleep((int) numericUpDown1.Value);
}


using a custom invoke it works just fine. I dont understand why it doesnt work correctly with the build in feature. This is also happening on the status progress bar as well.. Here is a quick app source.

Also it seems to work with the built in features using Win7 or above, Its freezing on windows xp sp3 


Edit: Never mind i can not attach rar, or .zip to this thread. 

Uploading a video to demonstrate.
Ivan Petrov
Telerik team
 answered on 25 Dec 2012
3 answers
121 views

In my properties window I see two GridViewTemplates:

  • GridViewTemplate1
  • GridViewTemplate2

GridViewTemplate2 is not associated with either RadGridView controlsI have on the page. Is there a way to delete this orphaned GridViewTemplate without going into the designer.vb code (I only do that as a last resort)?

Thanks.

Stefan
Telerik team
 answered on 24 Dec 2012
2 answers
176 views
Hi,

I'm using Telerik.WinControls.GridView version 2012.1.321.20.
I have a GridView with a GridViewComboBoxColumn, and the problem I have is that when the box is open and I click on the scroll square- than it's like the focus is out and the comboBox is closed (it's like freezing for 2 seconds and than closing...).

Also, I'm using the next definitions, as you recommended before:
public class CustomDropDownListEditor : RadDropDownListEditor
{
    protected override RadElement CreateEditorElement()
    {
        return new CustomDropDownListEditorElement();
    }
}
  
public class CustomDropDownListEditorElement : RadDropDownListEditorElement
{
    protected override RadPopupControlBase CreatePopupForm()
    {
        this.Popup = new CustomDropDownPopupForm(this);
        this.Popup.VerticalAlignmentCorrectionMode = AlignmentCorrectionMode.SnapToOuterEdges;
        this.Popup.SizingMode = this.DropDownSizingMode;
        this.Popup.Height = this.DropDownHeight;
        this.Popup.HorizontalAlignmentCorrectionMode = AlignmentCorrectionMode.Smooth;
        this.Popup.RightToLeft = this.RightToLeft ? System.Windows.Forms.RightToLeft.Yes : System.Windows.Forms.RightToLeft.Inherit;
  
        this.WirePopupFormEvents(this.Popup);
        return Popup;
    }
}
  
public class CustomDropDownPopupForm : DropDownPopupForm
{
    public CustomDropDownPopupForm(RadDropDownListElement owner): base(owner) {}
          
    public override string ThemeClassName
    {
        get { return typeof(DropDownPopupForm).FullName; }
        set {}
    }
  
    public override void ClosePopup(PopupCloseInfo info)
    {           
        base.ClosePopup(info);
        if (info.CloseReason == RadPopupCloseReason.Keyboard)
        {
            ((RadGridView)this.OwnerElement.ElementTree.Control).EndEdit();
        }
    }
  
    protected override void OnMouseUp(MouseEventArgs e)
    {
        base.OnMouseUp(e);           
        ((RadGridView)this.OwnerElement.ElementTree.Control).EndEdit();
    }
}
 
You should handle the EditorRequired event to replace the editor:
void radGridView1_EditorRequired(object sender, EditorRequiredEventArgs e)
{
    if (e.EditorType == typeof(RadDropDownListEditor))
    {
        e.EditorType = typeof(CustomDropDownListEditor);
    }
}

What should I do in order to not loose the focus when click on scrolling? I need the user to scroll up/doun and choose another option from the list.

I'm attaching an image of my comboBox.

Thanks,
Hila.

Elad
Top achievements
Rank 1
 answered on 23 Dec 2012
4 answers
345 views
Hello,

I use a Rad DateTimePicker in a certain application. What I want to achieve is to get the date that the user selects, along with the time of course, and send those using JScript to an asmx webservice as one of its arguments. What I did was that I sent the datetime as string from the JScript file and in the webservice I tried to parse that string back to datetime format using convert.todatetime method and I tried several other conversion methods but my problem was always one; and that is the string that's being sent is not recognized as a correct "convertible" datetime.

I debugged, and it's always sent as, for example, "2012-12-13-08-02-05" [this corresponds to 13/12/2012 08:02:05]. As you can see, this string really is not in one of the acceptable formats that the parsing methods accept.

I tried to change the input dateformat of the datetimepicker and it does change but only in displaying; it does not change in the string according to what I want [I mean the format I set is reflected on display only and not on save]. 

I'd really appreciate your help, thank you.
Diana
Top achievements
Rank 1
 answered on 22 Dec 2012
3 answers
129 views
Hi, i'm trying to do the Drag and Drop like the demo, but my first listbox it's conected with my dataset and when I do the drag and drop, gives me this error:

Data bound items can not be removed. Remove items from the data source instead.

If you can explain to me how to fix this. Thank You.
Stefan
Telerik team
 answered on 21 Dec 2012
1 answer
180 views

For those who might want to use this, I have created a quick sample on how to use linq to create dynamic series for chartview:

Example is created in VS2010 / VB.NET 

Make sure you import:
System.Data.DataSetExtensions.dll
to use linq.

Me.RadChartView1.ShowLegend = True
Me.RadChartView1.ShowTitle = True
Me.RadChartView1.Title = "Sold products per country"
 
        Dim graphSeries As New DataTable()
 
        graphSeries.Columns.Add("Category", GetType(String))
        graphSeries.Columns.Add("Value", GetType(Integer))
        graphSeries.Columns.Add("XValue", GetType(String))
 
 
        graphSeries.Rows.Add("Netherlands", 10, "2011")
        graphSeries.Rows.Add("USA", 12, "2011")
        graphSeries.Rows.Add("Germany", 7, "2011")
        graphSeries.Rows.Add("Netherlands", 25, "2012")
        graphSeries.Rows.Add("USA", 40, "2012")
        graphSeries.Rows.Add("Germany", 25, "2012")
 
       Dim productGroups = From p In graphSeries _
       Group p By Category = p.Field(Of String)("Category") Into Group _
                        Select Category, ProductGroup = Group
 
        For Each g In productGroups
            Dim barSeries As New Telerik.WinControls.UI.BarSeries("Value", "Category")
            barSeries.Name = g.Category
            barSeries.ValueMember = "Value"
            barSeries.CategoryMember = "XValue"
            barSeries.ShowLabels = True
            barSeries.LegendTitle = g.Category
            Me.RadChartView1.Series.Add(barSeries)
            barSeries.CombineMode = Telerik.Charting.ChartSeriesCombineMode.Stack
            barSeries.DataSource = g.ProductGroup.CopyToDataTable
 
        Next
Stefan
Telerik team
 answered on 21 Dec 2012
1 answer
177 views
I have set bmp images on commandbar buttons on the commandbar strip element. But, the images area not showing transparent..
Please find the attachments
Anton
Telerik team
 answered on 21 Dec 2012
1 answer
185 views
With the standard datagrid view in vs2010, I can highlight several rows in an excel sheet, containing, say title ID numbers, then left click on the datagrid and paste those values into the grid.

Is that even possible with the telerik grid view ?

Thanks.
Ivan Petrov
Telerik team
 answered on 21 Dec 2012
1 answer
203 views
Is there an example or can someone assist me in creating a simple bar chart while consuming data using entity framework?
The query could be as simple as:

SELECT        COUNT(Invoice_Header_Id) AS [Total Invoices], Created_By
FROM            Accounts_Payable.Invoice_Header
WHERE        (Date_Created >= CONVERT(DATETIME, '2012-12-19 00:00:00', 102))
GROUP BY Created_By

I don't have an entity created yet.  I would most likely use a store procedure and return a complex type.

Any help is appreciated.

Thanks
Bob
Missing User
 answered on 21 Dec 2012
5 answers
331 views
Hello.

I have a RadGridView with multiple date columns. When the user selects a date (using built-in editor) in any column, I want to save it in the database. If I use the RadGridView1_CellValueChanged event, I can get the new value using
radGridView1.CurrentRow.Cells[radGridView1.CurrentColumn.Name].Value.ToString()


but the drawback is that the user must click outside the cell to trigger the event. So I elected to use RadGridView1_ValueChanged instead, but then, the value doesn't seem to be written in the Gridview's cell at the time the event triggers so the line doesn't work as it always returns the old value.

How can I get the new user value from within RadGridView1_ValueChanged? Please consider that I also have spinner-type editors in the grid that will trigger the same way (and I want them to), so a code sample with multiple editor types on multiple columns would be of great help too.

Thanks alot.
Plamen
Telerik team
 answered on 21 Dec 2012
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
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?