Telerik Forums
UI for WPF Forum
2 answers
111 views

Hi,

I have some custom sorting for RadTreeView (ASC and DESC)...but I need the indicating arrows to go with them in my TextBlock above that triggers the sorting...Is that possible ? Any help is appreciated.

Barry

 

<TextBlock Text="{x:Static properties:Resources.GroupHeader}" MouseUp="TextBlock_MouseUp" TextAlignment="Center" Style="{StaticResource HeaderTemplate}" HorizontalAlignment="Stretch"/>

 

        //GROUP CUSTOM SEARCH
        private void TextBlock_MouseUp(object sender, MouseButtonEventArgs e)
        {
            isoProvider.LoadFromStorage(groupTreeViewIsolatedStorage); //GET

            IEnumerable<GroupVM> groups = GroupTree.ItemsSource as IEnumerable<GroupVM>;

            if (GroupTreeViewOrdering.Content.Equals(ConstantsUnit.Key_SortAscending))
            {
                IEnumerable<GroupVM> test = groups.OrderByDescending(p => p.Name);
                GroupTree.ItemsSource = null;
                while (GroupTree.ItemsSource == null) {
                    GroupTree.ItemsSource = test;
                }

                //GroupTree.ItemsSource = groups.OrderByDescending(p => p.Name);
                GroupTreeViewOrdering.Content = ConstantsUnit.Key_SortDescending;
            }
            else if (GroupTreeViewOrdering.Content.Equals(ConstantsUnit.Key_SortDescending))
            {
                IEnumerable<GroupVM> test = groups.OrderBy(p => p.Name);
                GroupTree.ItemsSource = null;
                while (GroupTree.ItemsSource == null) {
                    GroupTree.ItemsSource = test;
                }

                //GroupTree.ItemsSource = groups.OrderBy(p => p.Name);
                GroupTreeViewOrdering.Content = ConstantsUnit.Key_SortAscending;
            }

            isoProvider.SaveToStorage(groupTreeViewIsolatedStorage); //SET
        }

Barry
Top achievements
Rank 1
 answered on 10 Jun 2016
4 answers
410 views

Hello,

 

We're having some issues with the Telerik RadPDFViewer not printing correctly. When we were on the UI for WPF version 2016.1.112 the print worked fine. Now that we are on the new version 2016.2.503 the print isn't working as intended. 

 

The problem is if you have a multi page PDF in the PDFViewer and try and print it.

The PDF is converted to a byte array (to save to the database), then made into a MemoryStream, and then is passed to the PDFViewer. When you run the PDFViewer.Print() function it will send the PDF to the printer, but data only actually is printed on the first page and the following pages are just blank pages. The printer spits out the correct number of pages that are in the PDF but the first page is the only one that actually has something on it.

 

The reason we take the PDF and convert it to a byte array is because it's saved to the database for record and display later. This allows a user can come back later on and load the PDF that was saved to the database. It's loaded in from the database into a MemoryStream then to the PDFViewer.

 

I can provide a sample project that demonstrates the issue we are experiencing and how we are converting everything around. I would attach it but it wouldn't let me.

 

Telerik UI for WPF version: 2016.2.503 - May 03,2016

.Net Framework version: 4.0

 

Thanks in advance,

Kevin

Kevin
Top achievements
Rank 1
 answered on 10 Jun 2016
2 answers
77 views

Hello support guys,

 

I add a radgridview in a WPF usercontrol

[...]

radGridView1.ItemsSource = GetTable();

[...]

private DataTable GetTable()
{
// Here we create a DataTable with four columns.
DataTable table = new DataTable();
table.Columns.Add("Dosage");
table.Columns.Add("Drug");
table.Columns.Add("Patient");
table.Columns.Add("Date", typeof(DateTime));
// Here we add five DataRows.
table.Rows.Add(25, "Indocin", "David", DateTime.Now);
table.Rows.Add(50, "Enebrel", "Sam", DateTime.Now);
table.Rows.Add(10, "Hydralazine", "Christoff", DateTime.Now);
table.Rows.Add(21, "Combivent", "Janet", DateTime.Now);
table.Rows.Add(100, "Dilantin", "Melanie", DateTime.Now);
return table;
}

but when I trie filter a column, I cannot type anything in the filter textbox (see document attached). Is there any property to enable it?

Thank you in advance,

PP

 

 

pp
Top achievements
Rank 1
 answered on 10 Jun 2016
2 answers
84 views

Hi,

I am currently experiencing an issue where unpinned panes are cut off when mousing over the auto-hide tabs.
What's strange is that the first tab sizes correctly (could be any of the panes depending on the first one unpinned).

Here is a simple example:

<Window x:Class="Docking_Test.MainWindow"
        Title="MainWindow" WindowState="Maximized">
    <Grid>
        <telerik:RadDocking x:Name="radDock" HasDocumentHost="False">
            <telerik:RadSplitContainer Orientation="Vertical">
                <telerik:RadSplitContainer InitialPosition="DockedTop" telerik:ProportionalStackPanel.RelativeSize="100,80">
                    <telerik:RadSplitContainer InitialPosition="DockedLeft" telerik:ProportionalStackPanel.RelativeSize="40,100" Orientation="Vertical">
                        <telerik:RadPaneGroup>
                            <telerik:RadPane Header="Gauge" ContextMenuTemplate="{x:Null}">
                                <Viewbox Stretch="Uniform">
                                    <Border BorderThickness="5" BorderBrush="Black">
                                        <Rectangle Fill="Red" Width="600" Height="700"/>
                                    </Border>
                                </Viewbox>
                            </telerik:RadPane>
                        </telerik:RadPaneGroup>
                    </telerik:RadSplitContainer>
                    <telerik:RadSplitContainer InitialPosition="DockedRight" telerik:ProportionalStackPanel.RelativeSize="60,100" Orientation="Vertical">
                        <telerik:RadPaneGroup>
                            <telerik:RadPane Header="Charts" ContextMenuTemplate="{x:Null}">
                                <Border BorderThickness="5" BorderBrush="Black">
                                    <Rectangle Fill="Green" Width="1290" Height="700"/>
                                </Border>
                            </telerik:RadPane>
                        </telerik:RadPaneGroup>
                    </telerik:RadSplitContainer>
                </telerik:RadSplitContainer>
                <telerik:RadSplitContainer InitialPosition="DockedBottom" telerik:ProportionalStackPanel.RelativeSize="100,20">
                    <telerik:RadPaneGroup>
                        <telerik:RadPane Header="Timeline" ContextMenuTemplate="{x:Null}">
                            <Border BorderThickness="5" BorderBrush="Black">
                                <Rectangle Fill="Blue" Width="1900" Height="300"/>
                            </Border>
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
            </telerik:RadSplitContainer>
        </telerik:RadDocking>
    </Grid>
</Window>

 

Any help would be greatly appreciated!

Thanks,

Mike

Mike
Top achievements
Rank 1
 answered on 09 Jun 2016
11 answers
1.0K+ views
How to insert contents of a RichTextEdit box into the middle of a section in a RadDocument without adding a new section and without messing up the Table of Contents?

This will let the Table of Contents entries and page, header/footer to remain consistent throughout the document.

We've tried two ways to do this and both of them mess up the Table of Contents.  It erroneously removes entries from the Table of Contents. 

- InputDoc is the input MS Word docx document to copy from
- InputSection is the first section from InputDoc
- DestinationSection is the last Section added to the destination document.

Method 1 Tried: Use Block.DeepCopy()

Foreach (Block blk in inputSection.Blocks)
{
    Block blkTemp =blk.CreateDeepCopy() as Block;
    destinationSection.Blocks.Add(blockToInsert);
}

Method 2 Tried: Insert DocumentFragment()

inputDocument.Selection.SelectAll();
destinationDocument.CaretPosition.MoveToLastPositionInDocument();
RadDocumentEditor ed = new RadDocumentEditor(destinationDocument);
ed.InsertFragment(frag);

For method 2, how would one select  only the blocks under the first section
without selecting the first section.

.
Our application is a document assembly one which outputs a
Microsoft Word docs in the following format based on user preferences:

1. Title page
2. Table of Contents (each section has a numbered entry in the TOC, individual tables/images in the section also have numbered TOC entries)
3. One or more generated sections each containing a mix of tables and images
4. A custom section (see below)
5. One or more generated sections each containing a mix of tables and images
6. A custom section (see below)
7. One or more generated sections each containing a mix of tables and images
8. A custom section (see below)

Custom Section:

 - Each custom section is saved as docx files to disk 
 - Each custom section will be inserted back into the final output file
 - A custom section may be created days before the final document is assembled 
 - There may not be an active RichTextBox control loaded for a custom section when the final docx document is created
 - The custom section has only one section in it - it is not an arbitrary Word document
 - The custom section has a limited subset of functionality including text size, text color, bold, italic, text font, ...

The document is created in C# without any XAML.
The Table of Contents is a multi-level numbered list

Our application is a scientific one needing to output a mix of computed results as tables/graphs plus one or more user entered 1 to 2 page narratives.  Each narrative needs to support basic text formatting (font, font size, color, background color, bold/italic/etc, superscript, subscript, ...).

 

 

Boyko
Telerik team
 answered on 09 Jun 2016
4 answers
245 views

Hi,

I'm using the IsolatedStorage mechanism to get/set my sorts for all my RadGridView(s)...but I need arrows to indicate ASC or DESC for the user selection from the column headers.

Any tips ?

Barry

 

P.S. I'll also need the same for RadTreeView (which uses manual sorting)

Martin
Telerik team
 answered on 09 Jun 2016
1 answer
294 views

Hello,

I'm trying to apply the full text search to a grid that is bound to a data table (autogeneratecolumns=true).  But when I type in something it filters out everything.

If I look at the FilterMemberType and FilterMemberPath properties these are empty.

Also if I try using the default filtering (starts with) it shows an error in the filter box: "the method or operation is not implemented".

You also have this in the gridview examples if you look at "Various Data Source" and choose data table.

How can I fix this?

 

Stefan
Telerik team
 answered on 09 Jun 2016
4 answers
103 views

Hi,

Is there any way of closing the DragVisual window in the OnDrop Event Handler. The reason I ask is that I want to open a modal dialog when an item is dropped into a treeview. I am able to open the dialog as I want, but the DragVisual window will stay on top of the dialog. So in the OnDrop Event I want to close the DragVisual and then open the dialog window. Is this possible?

 

Regards,

Roar

Nasko
Telerik team
 answered on 09 Jun 2016
2 answers
230 views

Hi,

 

I'm trying to change the HEADER background but my only success left the control inoperable - the sorting and filtering did not work.

I need the *HEADER ROW* background to be this gradient:

        <Setter Property="Background">
            <Setter.Value>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStop Color="#FF25578A" Offset="0" />
                    <GradientStop Color="#FF25578A" Offset="1" />
                    <GradientStop Color="#FF25579A" Offset="0.42" />
                    <GradientStop Color="#FF003F87" Offset="0.43" />
                </LinearGradientBrush>
            </Setter.Value>
        </Setter>

..any help would be appreciated.

Barry

 

 

Dilyan Traykov
Telerik team
 answered on 09 Jun 2016
1 answer
108 views
(Level-1)
Scalar ---value
Enum  ---value
String ---Value
Boolean ---value
Array
    (Level-2)
    -Array 
        (Level-3)
        -Scalar ---value
        -Enum  ---value
        -String ---Value
        -Boolean ---value
    -Scalar ---value
    -Enum  ---value
    -String ---Value
    -Boolean ---value

I want to display the above tree in RadTreeListControl. The logic to extract "Value" property for each types(enums,scalar,array...) is different. How can I proceed?Can it be done by writing code behind logic? Also Does RadTreeListControl concept of ItemTemplateSelector?

Regards,

Niranjan

Maya
Telerik team
 answered on 09 Jun 2016
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
Slider
Expander
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
Book
FileDialogs
ToolBar
ColorPicker
TimePicker
SyntaxEditor
MultiColumnComboBox
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
DesktopAlert
WatermarkTextBox
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
ProgressBar
Sparkline
LayoutControl
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
WebCam
CardView
DataBar
Licensing
FilePathPicker
PasswordBox
Rating
SplashScreen
Accessibility
Callout
CollectionNavigator
Localization
AutoSuggestBox
HighlightTextBlock
Security
TouchManager
StepProgressBar
VirtualKeyboard
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
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?