Telerik Forums
UI for WinForms Forum
2 answers
911 views

I am trying to save the results of mail merge as a PDF, but I am getting a compiler error.

cannot convert from RadDocument to RadFixedDocument

Is there a way around it? Here's my code

using (SaveFileDialog dialog = new SaveFileDialog())
{
    dialog.Filter = "PDF (*.pdf)|*.pdf";
    dialog.FilterIndex = 2;
    dialog.RestoreDirectory = true;
 
    if (dialog.ShowDialog() == DialogResult.OK)
    {
        var provider = new  PdfFormatProvider();
        radRichTextEditor1.Document.MailMergeDataSource.ItemsSource = LetterService.GetEmployersMailMergeSource();
        using (Stream output = File.Create(dialog.FileName))
        {
            //error here
            provider.Export(radRichTextEditor1.Document.MailMerge(), output);
        }
    }
}

 

Pavel
Top achievements
Rank 1
 answered on 01 Dec 2016
8 answers
199 views

I want to give application admins to create new templates. Something like

Hello <LastName>, <FirstName>. You owe us <AmountOwed>. Please mail a check to <Address>. 

I spend some time research, and it appears that it's doable using RichTextEditor and MailMerge. However, I can't seem to find an ability for the user to actually create a template through a GUI. What am I missing?

Hristo
Telerik team
 answered on 01 Dec 2016
12 answers
2.5K+ views

Dear sirs,

I have data source in format of List<Dictionary<string,object>>. Can I bind the data to RadGridView.DataSource?

If it is not, can I extend some classes to do that?

Thanks for your sharing.

Tuan

Hristo
Telerik team
 answered on 01 Dec 2016
1 answer
183 views
I have a radspineditor, with a minimum of 1 and a maximum of 100. I want to display a messagebox if the user enters a value outside that range. How do I capture that value? That is, if the user enters 110 with the keyboard, display the messagebox.
Dimitar
Telerik team
 answered on 01 Dec 2016
5 answers
171 views

hi,

in my app i write subject "آقای حقیقت" but in Appointment Title it wrote "حقیقت آقای"

actually in the Appointment Title the Expression reversed,why?

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 01 Dec 2016
2 answers
110 views
Hi, I wanna create a theme based on VisualStudio2012Light theme, but I can't find these theme files, only the dll, where I can find them?
Dimitar
Telerik team
 answered on 01 Dec 2016
1 answer
137 views

I am trying to create a template editor for making letters for mailing.
I open up a new form with a RadRichTextEditor and an Editor Ribbon, and then assign a MailMergeDataSource.ItemsSource.
I add a few fields to the documents, and then use a DocxFormatProvider to get a byte[]
That array goes into an event with a Letter object inside. The event handler code is below.
All I want to do, is reload that byte[] into a different RadRichTextEditor, and then display the mailmerge fields like this <<MyCustomField>> and ideally highlight it. Instead, it's just displaying data from the ItemsSource. Below is the code that I think is relevant

private void LetterEditor_TemplateSaved(object sender, TemplateSavedEventArgs templateSavedEventArgs)
{
    var provider = new DocxFormatProvider();
    var doc = provider.Import(templateSavedEventArgs.Letter.LetterByteArray);
    radRichTextEditor1.Document = doc;
    radRichTextEditor1.Document.ShowMergeFieldsHighlight = true;
    radRichTextEditor1.Document.FieldsDisplayMode = Telerik.WinForms.Documents.Model.FieldDisplayMode.DisplayName;
}
Hristo
Telerik team
 answered on 30 Nov 2016
8 answers
408 views

I have the RadGrid properly changing the row backcolor based on the value of one column by utilizing the RowFormatting event handler, but this causes the selected row backcolor to no longer be the normal blue. Is there a way to set the row backcolor without effecting the selected row backcolor?

 

Thanks,

Greg Swope

 

Hristo
Telerik team
 answered on 30 Nov 2016
2 answers
626 views

As there is no event for Cell Mouse Enter or Cell Mouse Leave for a GridView, What event can I use to change the Mouse Cursor when the mouse hovers over a specific Cell?

I tried using the CellFormatting event to no avail.

 

01.Private Sub dgvVenItems_CellFormatting(sender As Object, e As Telerik.WinControls.UI.CellFormattingEventArgs) Handles dgvVenItems.CellFormatting
02.    Dim font As New System.Drawing.Font(SystemFonts.DialogFont, FontStyle.Underline)
03. 
04.    If e.CellElement.ColumnIndex = 0 Then
05.        e.CellElement.ForeColor = System.Drawing.Color.Blue
06.        e.CellElement.Font = font
07.        dgvVenItems.Cursor = Cursors.Hand
08.    Else
09.        e.CellElement.ResetValue(LightVisualElement.ForeColorProperty, ValueResetFlags.Local)
10.        dgvVenItems.Cursor = Cursors.Default
11.    End If
12.End Sub
Gone2TheDogs
Top achievements
Rank 2
Iron
Veteran
 answered on 30 Nov 2016
13 answers
302 views

In my RadMultiColumnCombobox. I have added two buttons to the  EditorControl's GridView area( image 2) . i want to add controls above and below of the radgridview. Also how to change the radgridview's header text color and  background as well as alternate row background like the image given below.( image 1).

Please help

 

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