Telerik Forums
UI for WPF Forum
0 answers
83 views
Hello Team,

Here we have a Telerik gridview and around 25 no. of columns is there. The problem is when we view Print Preview the output appears but not exactly what we expected. The 1st page take few columns and the rest goes to 2nd page and rest one goes to 3rd page but if we have 4 rows in a grid along with 25 columns, then the result must appear on the same page after the first best fit columns on the same page. 

Please see below the logic of Print Preview-

public
static void PrintPreview(GridViewDataControl source, bool modal)
        {
            var window = new Window { Title = "Print Preview" };
            var dialog = new PrintDialog();
            var document = source.ToPrintFriendly().ToFixedDocument(dialog);
            var documentViewer = new DocumentViewer
            {
                Document = document
            };
            window.Content = documentViewer;
            if (modal)
                window.ShowDialog();
            else
                window.Show();
        }

I have tried the given link in the forum and customise the logic but no luck to achieved what we expected as a output-
Here's link- http://www.telerik.com/community/code-library/wpf/gridview/radgridview-print-and-print-preview.aspx

Kindly help me out to over come this issue.

Regards,
Naren



  
Narendra
Top achievements
Rank 1
 asked on 09 Jun 2011
6 answers
451 views
Hi,
I am using a treeview in tri state mode. Initially the treeview is is collapsed mode. When I click and check on a collapsed parent node, its child nodes never gets checked automatically.
Once the parent node is expanded (and even if its collapsed then) and I check this node, its children are checked properly.

My requirement is to have all the nodes initially collapsed to parent level, when I check/uncheck a parent node, the node should expand and its children should get checked automatically.

Here is my markup for the treeview
<telerikNavigation:RadTreeView  Grid.Column="0" Grid.Row="0" x:Name="rdTreeView" ItemsOptionListType="CheckList" DockPanel.Dock="Bottom"
                    IsOptionElementsEnabled="True" IsRootLinesEnabled="True"  VerticalAlignment="Stretch" HorizontalAlignment="Stretch"
                    IsTriStateMode="True" Telerik:StyleManager.Theme="Office_Blue"
                    IsLineEnabled="True" IsEditable="True" Background="White" Margin="0,0,0,0" SelectionMode="Single"
                    IsExpandOnSingleClickEnabled="True" IsExpandOnDblClickEnabled="False"
                   BringIntoViewMode="HeaderAndItems" ItemContainerStyle="{StaticResource ItemContainerStyle}"
                    IsLoadOnDemandEnabled="False" IsVirtualizing="True"  telerikTreeView:TreeViewPanel.VirtualizationMode="Hierarchical"
                    Checked="rdTreeView_Checked" Unchecked="rdTreeView_Unchecked">
                    </telerikNavigation:RadTreeView>


Is there something I am missing? Please help.

Thanks
Tina Stancheva
Telerik team
 answered on 08 Jun 2011
1 answer
88 views
Hi,
I am having trouble getting the TileView to synchronize its maximized item with the current item from the ItemSource. I eventually got this to work by handling the appropriate event handlers but I'm wondering if there's something that I am doing wrong because it would certainly be much cleaner if I didn't have to do this. Here is how my control is defined:

 

<telerik:RadTileView
    x:Name="PART_TileView"
    ContentTemplate="{StaticResource ImageTileViewContentTemplate}"
    ItemsSource="{Binding Source={x:Static localdata:Image.ImageCollectionView}}"
    IsItemDraggingEnabled="False"
    IsSynchronizedWithCurrentItem="True"
    IsTextSearchEnabled="True"
    IsVirtualizing="True"
    ItemTemplate="{StaticResource ImageTileViewItemTemplate}"
    MinimizedColumnWidth="140"
    MinimizedItemsPosition="Right"
    MinimizedRowHeight="140"
    MaximizeMode="ZeroOrOne"
    TileStateChangeTrigger="SingleClick"
    TileStateChanged="RadTileView_TileStateChanged"
>
</telerik:RadTileView>

 

 

  

 

Thank you in advance for your excellent support.
Pete 

PS: I ran into a similar problem using the GridView when I bound 'ItemSource' to a collection. For that control I got the 'IsSynchronizedWithCurrentItem' behavior (thanks to your help) by binding to a collection view but that same trick isn't working for the TileView.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Zarko
Telerik team
 answered on 08 Jun 2011
4 answers
152 views
I have a tab control that has several tabs. each tab has a user control. All of the user controls are bound to an EF entity via viewModel binding. I've implemented some custom validation to my EF entity using IDataErrorInfo.

The main control is databound to master viewModel. Each child user control (which represents the contents of a tab) has its datacontext set to a property on the master viewModel (these properties are child viewmodels). These child VM are being instantiated once the master gets the entity from EF.

When I create a new tab control (for an entity), when it initially displays on the screen all my controls that are validation aware show the red outline I've defined for all properties that are required. But if I switch to a different tab then come back, the outlines are gone even though the value still doesn't pass validation. How do I fix this?

Is it in the way I have my UI designed? I can change it if needed, just not sure how.
Rayne
Top achievements
Rank 1
 answered on 08 Jun 2011
1 answer
124 views

Hi,

I'm using "PreservePositionWhenMaximized=True" in TileView.
Exception always occurs OnPropertyChanged when there is TileView item with Maximized state
But, no exception occurs OnPropertyChanged when  there isn't TileView item with Maximized state

  

what's the problem?

 

environment
telerik.windows.controls 2010.3.1314.40
visualstudio 2010
.net framework 4.0.303019
Win2003 SE SP2

StackTrace

at Telerik.Windows.Controls.RadTileView.ChangePosition(RadTileViewItem item, 
Int32 oldValue, Int32 newValue) in 
c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\Navigation\TileView\RadTileView.cs:line 
398<BR>   at 
Telerik.Windows.Controls.RadTileViewItem.OnPositionChanged(DependencyObject d, 
DependencyPropertyChangedEventArgs e) in 
c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\Navigation\TileView\RadTileViewItem.cs:line 
436<BR>   at 
System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs 
e)<BR>   at 
System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs 
e)<BR>   at 
System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs 
args)<BR>   at 
System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, 
DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, 
EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean 
coerceWithCurrentValue, OperationType operationType)<BR>   at 
System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object 
value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, Boolean 
coerceWithCurrentValue, OperationType operationType, Boolean 
isInternal)<BR>   at 
System.Windows.DependencyObject.SetValue(DependencyProperty dp, Object 
value)<BR>   at 

   

Zarko
Telerik team
 answered on 08 Jun 2011
10 answers
741 views
Lets say I have two columns in my data grid, Column A is a checkbox, and column B is text. I want to set the color of the text in Column B as Red, if the check box in the corresponding row is checked, and if not checked set the color to Black.

I want to do it through XAML. Can anyone provide me an example of how to do this?
Apoorva
Top achievements
Rank 1
 answered on 08 Jun 2011
3 answers
71 views
I have a WPF RadGridView with an associated ExportTelerikGridDataUserControl.
Using da-DK culture the XML export shows up in Excell with no decimals on numbers. I can solve this problem by using en-US culture but that has other implications that I cannot accept.
What can I do ?
Maya
Telerik team
 answered on 08 Jun 2011
0 answers
46 views

I m working on InstantMessaging application where I need to notify user whenever he/she recieved a new message. The problem is the application contains lots of screen and user can be on any screen. I want whenever user recieved a new message the notifier window will overlap the current window.

Kindly suggest...

swati
Top achievements
Rank 1
 asked on 08 Jun 2011
1 answer
70 views
Hi Admins,
How can I upload a sample here in forum for better description of problems?

Thank you.
Hristo
Telerik team
 answered on 08 Jun 2011
1 answer
169 views
Hi..
I when I create a PushPin.. it's the Red pushpin.  Are there any other built in 'Pins'?
How can I create a Blue, Yellow colored PushPin?
thanks again
Andrey
Telerik team
 answered on 08 Jun 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?