Telerik Forums
UI for WPF Forum
0 answers
68 views
Please delete this post as I have posted an other one.
AnnS
Top achievements
Rank 1
 asked on 16 Apr 2010
2 answers
63 views
Hello

I am filling a the items of the RadComboBox in the code behind.

            foreach (LJSDataSet.LJ_DBRow row in dbNew.LJ_DB.Rows)  
            {  
                StackPanel pan = new StackPanel();  
                TextBlock tb1 = new TextBlock();  
                TextBlock tb2 = new TextBlock();  
 
                tb1.Width = 130;  
                tb1.Text = row.DBNAME;  
 
                tb2.Width = 90;  
                tb2.Text = row.DBSERV;  
 
                pan.Orientation = Orientation.Horizontal;  
                pan.Children.Add(tb1);  
                pan.Children.Add(tb2);  
 
                this.comboDB.Items.Add(pan);  
            } 

When I compile the project, the combobox items are displayed as expected. But the SeletedItem always shows the type name
System.Windows.Contols.StackPanel.

How can I avoid this?

Thank you in advance.
Valeri Hristov
Telerik team
 answered on 16 Apr 2010
0 answers
33 views
It turned out the old style cause the problem.It's solved now.
Art Now
Top achievements
Rank 1
 asked on 16 Apr 2010
2 answers
223 views
I have a few grids, for which user can sort, filter, group and reorder columns. Also user can choose what are all columns he/she need to view in grid. All sort, filter, grouping and reordering are done by default, and i did visibility functionality by providing interface like add/remove columns, where user can choose hidden columns to show and visible columns to hide. After this selection i am setting IsVisible property of Grid.Columns in a loop.
Now I need to store all these settings per user basis in database and should load with the same state whenever he returns. Can I have any sample code to achieve this?
Siva
Top achievements
Rank 1
 answered on 16 Apr 2010
4 answers
265 views
I've got a RadDatePicker, and I'd like to be able to set the font of the days within the calendar, but can't find an obvious way of doing so.

Here's some code I tried:

        <telerik:RadDatePicker Grid.Row="4" Grid.Column="1" Name="DatePlanned"  
                               SelectedDate="{Binding SelectedDatePlanned, Mode=TwoWay}" > 
            <telerik:RadDatePicker.MonthViewStyle> 
                <Style> 
                    <Setter Property="Control.FontSize" Value="16" /> 
                </Style> 
            </telerik:RadDatePicker.MonthViewStyle> 
        </telerik:RadDatePicker> 

How can I accomplish this?
Kaloyan
Telerik team
 answered on 16 Apr 2010
1 answer
37 views
Hi, I'm getting this weird build error problem when I try to add a RadGridView in xaml, I've worked with other controls, and this is the first time it happens. Here's a screenshot, let me know if that is enough info:

http://www.telerik.com/community/forums/new-thread.aspx?forumId=284

Thanks!
Vlad
Telerik team
 answered on 16 Apr 2010
3 answers
95 views

Hi,


I''ve just upgraded to latest Q2 SP1 version of RadGridView and now  in the WPF designer i see the following exception.


'-2' is not a valid value for property'ViewportSize'.

   atSystem.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Objectvalue, PropertyMetadata metadata, Boolean coerceWithDeferredReference,OperationType operationType, Boolean isInternal)   atSystem.Windows.DependencyObject.SetValue(DependencyProperty dp, Objectvalue)   atSystem.Windows.Controls.Primitives.ScrollBar.set_ViewportSize(Doublevalue)   atTelerik.Windows.Controls.GridView.ScrollBarStateController.UpdateScrollBar(ScrollBarscrollBar, ScrollBarProperties properties)at Telerik.Windows.Controls.GridView.GridViewScrollViewer.UpdateScrollBars()   atTelerik.Windows.Controls.GridView.GridViewScrollViewer.GridViewScrollViewer_LayoutUpdated(Objectsender, EventArgs e)   atSystem.Windows.ContextLayoutManager.fireLayoutUpdateEvent()   atSystem.Windows.ContextLayoutManager.UpdateLayout()   atSystem.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)   at System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork()   atSystem.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()   atSystem.Windows.Media.MediaContext.RenderMessageHandlerCore(ObjectresizedCompositionTarget)   atSystem.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)   atSystem.Windows.Media.MediaContext.Resize(ICompositionTargetresizedCompositionTarget)   atSystem.Windows.Interop.HwndTarget.OnResize()at System.Windows.Interop.HwndTarget.HandleMessage(Int32 msg, IntPtrwparam, IntPtr lparam)   atSystem.Windows.Interop.HwndSource.HwndTargetFilterMessage(IntPtr hwnd, Int32msg, IntPtr wParam, IntPtr lParam, Boolean& handled)   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd,Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)   atMS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegatecallback, Object args, Boolean isSingleParameter)   atSystem.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegatecallback, Object args, Boolean isSingleParameter, Delegate catchHandler)

Thanks,
Ruben.
Hristo
Telerik team
 answered on 15 Apr 2010
8 answers
358 views
Hi,

it seems the RadScheduler's drag 'n' drop behaviour has changed.
Inside my AppointmentTemplates for the Day-View I have a lot of "custom" drag 'n' drop functionality (and scrollviewers) which was no problem before.
But with the beta the RadGridView's own Drag'n'Drop starts immediately and tries to move the appointment.

How can I disable the drag'n'drop? Or maybe there is another solution.

Best Regards
Steffen
Teodor
Telerik team
 answered on 15 Apr 2010
12 answers
366 views
I want to change the Foreground and Background of the Month and Year Button (Currently by default the foreground is grey and the background also). What is the simplest way of doing that.

Attached is the current view (December 2009)

Thanks,
Anjan
Konstantina
Telerik team
 answered on 15 Apr 2010
1 answer
119 views
Hello.

I have trouble to programatically acces element in TitleTemplate of RadPane.
I have this following style applied to my RadPane, where is also specified the DataTemplate of TitleTemplate.
For example I would like to acces the "PART_ParentControls" element. Can you please help me ?
Thanks a lot.
Here is the style xaml:

   <Style x:Key="TelerikRadPaneStyle1" TargetType="{x:Type telDockingControls:RadPane}">
        <Setter Property="CanUserPin" Value="False" />
        <Setter Property="CanFloat" Value="True" />
        <Setter Property="CanUserClose" Value="False" />
        <Setter Property="ContextMenuTemplate">
            <Setter.Value>
                <DataTemplate>
                    <telNavigationControls:RadContextMenu Visibility="Collapsed" />
                </DataTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="TitleTemplate">
            <Setter.Value>
                <DataTemplate >
                    <Grid x:Name="mainGrid">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="20" />
                            <ColumnDefinition Width="*" />
                            <ColumnDefinition Width="Auto" />
                        </Grid.ColumnDefinitions>

                        <Border BorderThickness="1" BorderBrush="Black" Margin="0,5,2,5" >
                            <Canvas Grid.Column="0" Background="White" Opacity="1" IsHitTestVisible="True" ToolTip="Drag to move the window" />
                        </Border>
                        
                         <breadCrumbBar:BreadcrumbBar x:Name="bar" Grid.Column="1" Margin="1" Path="News"
                                                            TraceBinding="{Binding XPath=@title}" BorderBrush="{x:Null}"
                                                            Root="{StaticResource dataProvider}" Background="Transparent"
                                                            >
                            <breadCrumbBar:BreadcrumbBar.PreButtons>
                                <Button>
                                    <Image Style="{StaticResource Backward}" Opacity="0.8" Width="16" Height="16"/>
                                </Button>
                                <Button>
                                    <Image Style="{StaticResource Forward}" Opacity="0.8" Width="16" Height="16"/>
                                </Button>
                            </breadCrumbBar:BreadcrumbBar.PreButtons>
                            <breadCrumbBar:BreadcrumbBar.Buttons>
                                <Button>
                                    <Image Style="{StaticResource Close}" Opacity="0.5" Width="16" Height="16" HorizontalAlignment="Right"/>
                                </Button>
                            </breadCrumbBar:BreadcrumbBar.Buttons>
                        </breadCrumbBar:BreadcrumbBar>
                        
                        <Grid Grid.Column="2" x:Name="PART_ParentControls" />
                        
                    </Grid>
                </DataTemplate>
            </Setter.Value>
        </Setter>
    </Style>
Miroslav Nedyalkov
Telerik team
 answered on 15 Apr 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?