Telerik Forums
UI for WinForms Forum
1 answer
13 views

I am trying to figure out if updating different packages in my project is possible and would like to find the documentation for my Telerik version. I have a old version and can't find relevant information anywhere.

Is there some legacy page i can view?

Mihaela
Telerik team
 answered on 19 Feb 2024
1 answer
28 views

public void WriteToWordDocumentContinued(){

    m_document = new RadFlowDocument();
    m_editor = new RadFlowDocumentEditor(m_document);
    Section section = new Section(m_document);
    section.HasDifferentFirstPageHeaderFooter = true;
    section.PageMargins = new Telerik.Windows.Documents.Primitives.Padding(56.69, 94.49, 47.24, 66.14);
    m_document.Sections.Add(section);
    m_document.StyleRepository.AddBuiltInStyle(BuiltInStyleNames.GetHeadingStyleIdByIndex(1));


    Style MainTitle = new Style("MainTitle", StyleType.Character) { };
    MainTitle.CharacterProperties.UnderlinePattern.LocalValue = UnderlinePattern.Single;
    MainTitle.CharacterProperties.FontFamily.LocalValue = new ThemableFontFamily("Arial");
    MainTitle.CharacterProperties.FontSize.LocalValue = 32;
    MainTitle.CharacterProperties.FontWeight.LocalValue = System.Windows.FontWeights.Bold;
    m_document.StyleRepository.Add(MainTitle);

    Style HeaderParagraphStyle = new Style("HeaderParagraphStyle", StyleType.Paragraph) { };
    HeaderParagraphStyle.ParagraphProperties.LineSpacing.LocalValue = 16;
    HeaderParagraphStyle.ParagraphProperties.LineSpacingType.LocalValue = HeightType.Exact;
    HeaderParagraphStyle.ParagraphProperties.SpacingAfter.LocalValue = 0;
    HeaderParagraphStyle.ParagraphProperties.SpacingBefore.LocalValue = 0;

    Style HeaderTitleStyle = new Style("HeaderTitleStyle", StyleType.Paragraph) { };
    HeaderTitleStyle.ParagraphProperties.LineSpacing.LocalValue = 21.4;
    HeaderTitleStyle.ParagraphProperties.LineSpacingType.LocalValue = HeightType.Exact;
    HeaderTitleStyle.ParagraphProperties.SpacingAfter.LocalValue = 0;
    HeaderTitleStyle.ParagraphProperties.SpacingBefore.LocalValue = 0;
    HeaderTitleStyle.ParagraphProperties.TextAlignment.LocalValue = Alignment.Right;

    HeaderParagraphStyle.ParagraphProperties.TextAlignment.LocalValue = Alignment.Right;
    m_document.StyleRepository.Add(HeaderParagraphStyle);

    Style HeaderCharacterStyle = new Style("HeaderCharacterStyle", StyleType.Paragraph) { };
    HeaderCharacterStyle.CharacterProperties.FontFamily.LocalValue = new ThemableFontFamily("Arial");
    HeaderCharacterStyle.CharacterProperties.FontSize.LocalValue = 16;
    m_document.StyleRepository.Add(HeaderCharacterStyle);

    Style SubTitle = new Style("SubTitle", StyleType.Character) { };
    SubTitle.CharacterProperties.UnderlinePattern.LocalValue = UnderlinePattern.Single;
    SubTitle.CharacterProperties.FontFamily.LocalValue = new ThemableFontFamily("Arial");
    SubTitle.CharacterProperties.FontSize.LocalValue = 16;
    SubTitle.CharacterProperties.FontWeight.LocalValue = System.Windows.FontWeights.Bold;
    m_document.StyleRepository.Add(SubTitle);

    Style TopLines = new Style("TopLines", StyleType.Character) { };
    TopLines.CharacterProperties.FontFamily.LocalValue = new ThemableFontFamily("Arial");
    TopLines.CharacterProperties.FontSize.LocalValue = 16;
    TopLines.CharacterProperties.FontWeight.LocalValue = System.Windows.FontWeights.Bold;
    m_document.StyleRepository.Add(TopLines);

}

 

This is just minified version of the method where I am trying to instantiate my RadFlowDocument object. This method is being called in a parent class, even If I try to pass RadFlowDocument object from that class, it still causes the UI to break. 

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 26 Sep 2023
1 answer
84 views

Hello all

(sorry for my english)

I tried to use the example 5 and 6 on this page :

 https://docs.telerik.com/devtools/document-processing/libraries/radwordsprocessing/editing/mail-merge

But it don't work.

"MERGEFIELD" work but "MERGEFIELD TableStart:" don't. 

What did i do wrong ?

 

Thank you very much for answers :)

Please see Below the code :

Imports System
Imports System.Collections.Generic
Imports System.ComponentModel
Imports System.Data
Imports System.Drawing
Imports System.IO
Imports System.Linq
Imports System.Reflection
Imports System.Text
Imports System.Windows
Imports System.Windows.Forms
Imports Telerik.Windows.Documents.Common.FormatProviders
Imports Telerik.Windows.Documents.Flow.FormatProviders.Docx
Imports Telerik.Windows.Documents.Flow.FormatProviders.Html
Imports Telerik.Windows.Documents.Flow.FormatProviders.Rtf
Imports Telerik.Windows.Documents.Flow.FormatProviders.Txt
Imports Telerik.Windows.Documents.Flow.Model
Imports Telerik.Windows.Documents.Flow.Model.Editing
Imports Telerik.Windows.Documents.Flow.Model.Styles
Imports Telerik.Windows.Documents.Spreadsheet.Model
Imports Telerik.Windows.Documents.Core
Imports Telerik.Windows.Documents.Flow
Imports Telerik.WinForms.Documents.FormatProviders.Pdf

Module M_TestGenerationDoc

    Private ReadOnly providers As Dictionary(Of IFormatProvider(Of RadFlowDocument), String)
    Private chemin As String = "C:\Temp\MODELE\"
    Private selectedFormat As String = "Docx"

Public Sub S_TestFusion()
        Dim document As RadFlowDocument = New RadFlowDocument()
        Dim editor As RadFlowDocumentEditor = New RadFlowDocumentEditor(document)

        editor.InsertParagraph()
        editor.InsertField("MERGEFIELD TeamName", "")
        editor.InsertParagraph()
        editor.InsertText("Players:")

        Dim playersTable As Table = editor.InsertTable(2, 2)
        playersTable.PreferredWidth = New TableWidthUnit(TableWidthUnitType.Percent, 100)
        document.StyleRepository.AddBuiltInStyle(BuiltInStyleNames.TableGridStyleId)
        playersTable.StyleId = BuiltInStyleNames.TableGridStyleId

        playersTable.Rows(0).Cells(0).Blocks.AddParagraph().Inlines.AddRun("First Name")
        playersTable.Rows(0).Cells(1).Blocks.AddParagraph().Inlines.AddRun("Last Name")

        Dim firstNameParagraph As Paragraph = playersTable.Rows(1).Cells(0).Blocks.AddParagraph()
        editor.MoveToParagraphStart(firstNameParagraph)
        editor.InsertField("MERGEFIELD TableStart:Players", "")
        editor.InsertField("MERGEFIELD FirsName", "")

        Dim lastNameParagraph As Paragraph = playersTable.Rows(1).Cells(1).Blocks.AddParagraph()
        editor.MoveToParagraphStart(lastNameParagraph)
        editor.InsertField("MERGEFIELD LastName", "")
        editor.InsertField("MERGEFIELD TableEnd:Players", "")

        Dim mailMergeResult As RadFlowDocument = document.MailMerge(GetTeams())


        SaveDocument(mailMergeResult, selectedFormat)

        MsgBox("Fichier sauvegardé")

    End Sub

 Public Function SaveDocument(ByVal document As RadFlowDocument, ByVal selectedFormat As String) As Boolean
        Dim formatProvider As IFormatProvider(Of RadFlowDocument) = Nothing

        Try
            Select Case selectedFormat
                Case "Docx"
                    formatProvider = New DocxFormatProvider()
                Case "Rtf"
                    formatProvider = New RtfFormatProvider()
                Case "Html"
                    formatProvider = New HtmlFormatProvider()
                Case "Txt"
                    formatProvider = New TxtFormatProvider()
                Case "Pdf"
                    formatProvider = New PdfFormatProvider()
            End Select

            If formatProvider Is Nothing Then
                Return False
            End If

            Dim dialog As SaveFileDialog = New SaveFileDialog()
            dialog.FileName = "Result"
            dialog.Filter = String.Format("{0} files|*{1}|All files (*.*)|*.*", selectedFormat, formatProvider.SupportedExtensions.First())
            dialog.FilterIndex = 1

            Using output As Stream = File.OpenWrite(chemin + "test_fusion.docx")
                formatProvider.Export(document, output)
            End Using

            Return True

        Catch ex As Exception
            MsgBox(ex.Message)
            Return False
        End Try


    End Function


Public Function GetTeams() As List(Of Team)
        Dim teams = New List(Of Team)()
        Dim team1 = New Team()
        team1.TeamName = "Team 1"
        team1.Players.Add(New Player() With {
            .FirsName = "John",
            .LastName = "Baker"
        })
        team1.Players.Add(New Player() With {
            .FirsName = "Sam ",
            .LastName = "Wayne"
        })
        teams.Add(team1)
        Dim team2 = New Team()
        team2.TeamName = "Team 2"
        team2.Players.Add(New Player() With {
            .FirsName = "Patrick",
            .LastName = "Gibbs"
        })
        team2.Players.Add(New Player() With {
            .FirsName = "Oscar",
            .LastName = "Stevens"
        })
        teams.Add(team2)
        Return teams
    End Function

    Public Class Team
        Public Property TeamName As String
        Public Property Players As List(Of Player)

        Public Sub New()
            Me.Players = New List(Of Player)()
        End Sub

    End Class

    Public Class Player
        Public Property FirsName As String
        Public Property LastName As String
    End Class

End Module


Vladislav
Telerik team
 answered on 17 Feb 2022
1 answer
200 views

Hello,

We are having an issue with our application on high DPI monitors. When the PdfViewer loads a document, it resizes the whole application. The issue only occurs with the published application. It does not happen on debug mode. See attached video.

Thank you,

video: https://drive.google.com/file/d/1N_JkCRQ6GNOYgsL3PrwOYm0hOBPpaGn8/view?usp=sharing

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 17 Feb 2021
1 answer
193 views
Hello, i have developed a c# windows form application and i have a problem deploing the solution in other computers.
PS: I must run,deploy the solution in other computer that doesn't have SQL SERVER or VS installed. (It worked with other solution)

What I have tried:

I worked with Telerik and I just for each Telerik assembly reference in the Solution Explorer, on properties and in the property grid set the Copy Local property of the reference to True.
When i try to install the .exe from other copmuter i get this error :

Cannot install or run app. this app requires Telerik.WinControls assembly version 2020.2.616.20, which must first be installed in the global assambly cache
Dess | Tech Support Engineer, Principal
Telerik team
 answered on 22 Jan 2021
1 answer
34 views

Hi all,

I'm an onbording programmer and also new to Telerik.  I'm taking a look at Telerik products.  More specificaly at the Windows form TreeView from VS 2019 VB.NET.

I just tried to create a new Windows form project and added a RadTreeView.  I try to add nodes but they don't show up in the TreeView.  What I'm I doing wrong ?

 

I'm attaching a picture of the verry simple code with hope this can help you.

 

This is my first time here so I'm not sure if:

- I provide appropriate information

- I'm at the right place for that type of support

 

Just let me know!

 

Erik

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 23 Dec 2020
3 answers
37 views

Program uses spell check and autocomplete on a radtextbox control.

In order to use ILMerge, I have:

Telerik.WinControls.RadTypeResolver.Instance.ResolveTypesInCurrentAssembly = True

Near top of main form.

 

 

References in Solution Explorer show: 

Telerik.WinControls

Telerik.WinControls.SpellChecker

Telerik.WinControls.UI

Telerik.WinControls.Design

 

However, when I build the program, I find just about every major Telerik assembly dll, From PdfView, to RadWebCam.
I've searched the entire solution, and can't figure out where all those references are coming from.

 

Where did I go wrong?

 

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 03 Jun 2020
1 answer
1.0K+ views

Hi Team, 

I am unable to find the direct download links for older versions of telerik. I am looking for for 2018 R3 version for windows. 

Thanks, 

Vijay

Nadya | Tech Support Engineer
Telerik team
 answered on 28 Jan 2020
1 answer
94 views

Hi,

I have three GridViewComboBoxColumn in RadGridView. Each Combobox column has display name and selected value code. When I assign the value, corresponding values are assigning correctly. But when when I fetch the row, Code value is coming as null and code value is displaying in name. I have attached the image.

The following code I have used to bind data to GridViewComboBoxColumn.

 ((GridViewComboBoxColumn)this.dataGrid.Columns["Company_Name"]).ItemsSource = CompanyList;
 ((GridViewComboBoxColumn)this.dataGrid.Columns["Company_Name"]).DisplayMemberPath = "Company_Name";
 ((GridViewComboBoxColumn)this.dataGrid.Columns["Company_Name"]).SelectedValueMemberPath = "Company_Code_Hdn";

Vladimir Stoyanov
Telerik team
 answered on 23 Jan 2020
3 answers
123 views

Hi,

I'm currently new to Telerik, which my company used in the past. One of my first task is to upgrade and copy a project by manually rewriting the files to avoid publishing issues.  I came across an error which I can't seem to find the solution.  It appears that Pdf class is no longer under Telerik.Windows.  I see that there's a Telerik.Pdf now but I can't seem to figure out what to use to make my project error-free.  Can anyone help me with this?

 

Visual Studio Error at the beginning of my form:
using Telerik.Windows.Pdf.Documents.Fixed.Model.Navigation;



Severity: Error, Code: CS0234, Description: The type or namespace name 'Pdf' does not exist in the namespace 'Telerik.Windows' (are you missing an assembly reference?), Project: Label Printing PVC, File:C:\Users\Lily\Documents\Visual Studio 2017\Projects\Label Printing PVC\Label Printing PVC\APrintLabelSystemProdGroupNew.cs, Line 10, Suppression State: Active


Tanya
Telerik team
 answered on 13 May 2019
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
Buttons, RadioButton, CheckBox, etc
DropDownList
ComboBox and ListBox (obsolete as of Q2 2010)
ListView
Chart (obsolete as of Q1 2013)
Form
PageView
MultiColumn ComboBox
TextBox
Menu
RichTextEditor
PropertyGrid
RichTextBox (obsolete as of Q3 2014 SP1)
Panelbar (obsolete as of Q2 2010)
Tabstrip (obsolete as of Q2 2010)
PivotGrid and PivotFieldList
MaskedEditBox
CommandBar
PdfViewer and PdfViewerNavigator
ListControl
Carousel
Diagram, DiagramRibbonBar, DiagramToolBox
Panorama
GanttView
New Product Suggestions
Toolstrip (obsolete as of Q3 2010)
AutoCompleteBox
Label
VirtualGrid
Spreadsheet
ContextMenu
Panel
Visual Studio Extensions
TitleBar
SplitContainer
Map
DesktopAlert
ProgressBar
Rotator
TrackBar
MessageBox
CheckedDropDownList
SpinEditor
StatusStrip
CheckedListBox
Wizard
ShapedForm
SyntaxEditor
TextBoxControl
LayoutControl
CollapsiblePanel
Conversational UI, Chat
DateTimePicker
CAB Enabling Kit
TabbedForm
DataEntry
GroupBox
ScrollablePanel
WaitingBar
ImageEditor
ScrollBar
Tools - VSB, Control Spy, Shape Editor
BrowseEditor
DataFilter
ColorDialog
FileDialogs
Gauges (RadialGauge, LinearGauge, BulletGraph)
ApplicationMenu
RangeSelector
CardView
WebCam
BindingNavigator
PopupEditor
RibbonForm
TaskBoard
Barcode
Styling
ColorBox
PictureBox
Callout
VirtualKeyboard
FilterView
Accessibility
DataLayout
NavigationView
ToastNotificationManager
CalculatorDropDown
Localization
TimePicker
ValidationProvider
FontDropDownList
Licensing
BreadCrumb
ButtonTextBox
LocalizationProvider
Dictionary
Overlay
Security
Separator
SparkLine
TreeMap
StepProgressBar
SplashScreen
ToolbarForm
NotifyIcon
Rating
TimeSpanPicker
BarcodeView
Calculator
OfficeNavigationBar
Flyout
TaskbarButton
HeatMap
SlideView
PipsPager
+? more
Top users last month
horváth
Top achievements
Rank 2
Iron
Iron
Steve
Top achievements
Rank 2
Iron
Erkki
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 2
Iron
Iron
Veteran
Jakub
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
horváth
Top achievements
Rank 2
Iron
Iron
Steve
Top achievements
Rank 2
Iron
Erkki
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 2
Iron
Iron
Veteran
Jakub
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?