Telerik Forums
UI for WPF Forum
1 answer
92 views
Hi, this might sound like a strange question but

If I have a CartesianChart bound to the following sample data:

category (DateTime): 01.01.2000 value 1
category (DateTime): 01.01.2000 value 2

this data is bound to a barseries and the categorybinding and valuebinding are set to the respective fields,
the horizontal x axis contains a DateTimeCategoriesAxis.

When i run this two bars are together and one category is shown which is kind of logical in the sense that it's the same category.

Is there however some way of forcing the x-axis to treat each category as a separate category instead? so that the two bars have spacing between them and are in their respective "category" similar to how Excel does things.
Petar Marchev
Telerik team
 answered on 23 Nov 2012
1 answer
371 views
Hi,

i'm validaitin my Item with "ValidatinItem="MyForm_ValidatinItem":
private void VerbindungForm1_ValidatingItem(object sender, System.ComponentModel.CancelEventArgs e)
{
var employer = this.VerbindungForm1.CurrentItem as Verbindungen;
if (employer.Name.Count() < 1)
{
RadWindow.Alert("You have to enter a " + employer.Name);
}
}

This Works fine, but is it possible to chance the background of this fild now? Or set a border with Tooltip? And how do i stop the Comit if the Validation is false?

Thanks Best Regards
Rene
Yoan
Telerik team
 answered on 23 Nov 2012
1 answer
118 views
Hi,

I'm getting the following XAML design time exception in VS2012.

Exception

NullReferenceException: Object reference not set to an instance of an object.

Here's the stack trace:

   at Telerik.Windows.Controls.RichTextBoxUI.StatusBar.LayoutModeSelector.get_SelectedLayoutMode()
   at Telerik.Windows.Controls.RichTextBoxUI.StatusBar.LayoutModeSelector.set_SelectedLayoutMode(DocumentLayoutMode value)
   at Telerik.Windows.Controls.RichTextBoxUI.RadRichTextBoxStatusBar.OnDocumentLayoutModeChanged()
   at Telerik.Windows.Controls.RichTextBoxUI.RadRichTextBoxStatusBar.OnAssociatedRichTextBoxChanged(DependencyObject o, DependencyPropertyChangedEventArgs e)
   at System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e)
   at System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e)
   at System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args)
   at System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType)
   at System.Windows.DependencyObject.InvalidateProperty(DependencyProperty dp, Boolean preserveCurrentValue)
   at System.Windows.Data.BindingExpressionBase.Invalidate(Boolean isASubPropertyChange)
   at System.Windows.Data.BindingExpression.TransferValue(Object newValue, Boolean isASubPropertyChange)
   at System.Windows.Data.BindingExpression.Activate(Object item)
   at System.Windows.Data.BindingExpression.AttachToContext(AttachAttempt attempt)
   at System.Windows.Data.BindingExpression.MS.Internal.Data.IDataBindEngineClient.AttachToContext(Boolean lastChance)
   at MS.Internal.Data.DataBindEngine.Task.Run(Boolean lastChance)
   at MS.Internal.Data.DataBindEngine.Run(Object arg)
   at MS.Internal.Data.DataBindEngine.OnLayoutUpdated(Object sender, EventArgs e)
   at System.Windows.ContextLayoutManager.fireLayoutUpdateEvent()

Any idea's what may be causing it?

Thanks,

Rob
Boby
Telerik team
 answered on 23 Nov 2012
0 answers
148 views
i already created gridbound column.. wanted to add numbering column due to user request.
i get Error: system.data.datarowview at No column.



<telerik:GridBoundColumn UniqueName="RowNumber" HeaderText="No" EditFormColumnIndex="1"></telerik:GridBoundColumn>


aspx.cs:

        protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e)
        {
            if (e.Item is GridDataItem)
            {
                GridDataItem dataItem = (GridDataItem)e.Item;
                dataItem["RowNumber"].Text = Convert.ToString(e.Item.ItemIndex + 1);


            }
        }
Kaizen
Top achievements
Rank 1
 asked on 23 Nov 2012
5 answers
98 views
Hi,

I have this RadGridView:
<telerik:RadGridView x:Name="RadGridView1" GroupRenderMode="Flat" IsSynchronizedWithCurrentItem="True"
    IsReadOnly="True"
    AutoGenerateColumns="False"
    CanUserFreezeColumns="False"
    CanUserResizeColumns="True">
    <telerik:RadGridView.Columns>
        <telerik:GridViewDataColumn Header="#Case" DataMemberBinding="{Binding caseId}" Width="Auto"></telerik:GridViewDataColumn>>
        <telerik:GridViewDataColumn Name="CategoriesGridViewDataColumn" Header="Categories" Width="Auto">
            <telerik:GridViewDataColumn.CellTemplate>
                <DataTemplate>
                    <Grid Margin="0" Name="categoriesGird">
                        <Grid.RowDefinitions>
                            <RowDefinition Height="1*"/>
                        </Grid.RowDefinitions>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="1*"/>
                            <ColumnDefinition Width="1*"/>
                        </Grid.ColumnDefinitions>
                        <TextBlock Grid.Row="0" Grid.Column="0" Background="Red"></TextBlock>
                        <TextBlock Grid.Row="0" Grid.Column="1" Background="Blue"></TextBlock>
                    </Grid>
                </DataTemplate>
            </telerik:GridViewDataColumn.CellTemplate>
        </telerik:GridViewDataColumn>
    </telerik:RadContextMenu.ContextMenu>
</telerik:RadGridView>

This give me something like the image in attachments.
As you can see I have 2 TextBlock for each row (column categories). But I want to fill the GridView table with information that I have in a a class that i created (number of categories is dynamic, so I want the number of TextBlock for each row depends how many categories i have in a list):
public class EmailTest
{
       public EmailTest() { }
 
       public EmailTest(string caseId, List<TextBlock> categories)
       {
          this.caseId = caseId;
          this.categories= categories;
       }
 
       public string caseId{ getset; }
       public List<TextBlock>categories{ getset; }
  }


How can I solve this problem?
Hadrien
Top achievements
Rank 1
 answered on 22 Nov 2012
1 answer
128 views
Hello,

the PivotGrid is a really great control. When is it planned to be final? And will the final control contain some exporting functionality?

Best regards,

Michael
Rosen Vladimirov
Telerik team
 answered on 22 Nov 2012
1 answer
64 views
I am generating a pie chart in c# code. The resulting pie chart looks good, except that the labels are all straight along the centre, instead of where they are supposed to be, as can be seen in the image. Any idea what I am doing incorrectly?

Mike
Top achievements
Rank 1
 answered on 22 Nov 2012
1 answer
146 views
After following the instruction in the forum post How do you enter multiple lines of text in a cell I now have a nice way to enter multiple lines of text into a cell of my RadGridView control however if you actually attempt to use this for text that is of any significant size you will notice that the RadGridView control will not scroll along with keyboard cursor within the TextBox. To see the effect load the example from the aforementioned post and attempt to type in the the second column and create enough lines so that the text wraps past the bottom of the visible scroll region of the RadGridView. Has anybody found away to work around this? I've noticed all of the scroll into view methods but none seem to be specific to a position within a child control of an edit template of a column of the RadGridView. I'm guessing one could look for changes in size of the hosted TextBox and then attempt to adjust the scroll position of the RadGridView but I'm wondering if anybody else has already solved this problem as it seems like it would be a common one.

After writing this post I realized that the same issue may also exist when entering simple single line text where the right portion of the column happens to be partially off of the horizontal scroll region and sure enough that also exhibits the same problem So I guess my question is a general one, how to make RadGridView follow the keyboard cursor when editing text in one of the cells?
Yoan
Telerik team
 answered on 22 Nov 2012
1 answer
169 views
Is it possible to defer the filtering until some point, suchas when the DataFilter loses focus?
Thanks in advance,
Steve
Dimitrina
Telerik team
 answered on 22 Nov 2012
0 answers
137 views

Hello,

Is it possible to bind two comboboxes to one table with composite primary key?

Suppose one has a table MyTable with two fields (int Level, varchar2 Code) which forms composite primary key.

The corresponding entity is

public class MyTable
{
   public MyEnum Level {get; set;}
   public string Code {get; set;}
}

where MyEnum is some enum.

I would like to bind two comboboxes to the list of such entities so that one combobox shows list of available items of MyEnum,

and the other one list of codes corresponding to the selected Level. Is it possible?

Thanks in advance.

Yours faithfully,

Mikhail.

MuxMux
Top achievements
Rank 1
 asked on 22 Nov 2012
Narrow your results
Selected tags
Tags
GridView
General Discussions
Chart
RichTextBox
Docking
ScheduleView
ChartView
TreeView
Diagram
Map
ComboBox
TreeListView
Window
RibbonView and RibbonWindow
PropertyGrid
DragAndDrop
TabControl
TileView
Carousel
DataForm
PDFViewer
MaskedInput (Numeric, DateTime, Text, Currency)
AutoCompleteBox
DatePicker
Buttons
ListBox
GanttView
PivotGrid
Spreadsheet
Gauges
NumericUpDown
PanelBar
DateTimePicker
DataFilter
Menu
ContextMenu
TimeLine
Calendar
Installer and Visual Studio Extensions
ImageEditor
BusyIndicator
Expander
Slider
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
FileDialogs
Book
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
WatermarkTextBox
DesktopAlert
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
LayoutControl
ProgressBar
Sparkline
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
Licensing
WebCam
CardView
DataBar
FilePathPicker
PasswordBox
SplashScreen
Callout
Rating
Accessibility
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?