We are using your trial version .Now we face some problems for radrichtextbox
1. We save document by following code
public void ExportContent(string defaultExtension, string filter,IDocumentFormatProvider formatProvider)
{
var saveFileDialog = new SaveFileDialog
{
DefaultExt = defaultExtension,
Filter = filter
};
saveFileDialog.FileName = wordfilepath;
using (var outputStream = saveFileDialog.OpenFile())
{
formatProvider.Export(radRichTextBox1.Document, outputStream);
}
}
2 . Now when we insert picture using teleriks insert picture method .Picture is inserted and file is saved by above method.Then on another form we cannot display this image on richtextbox .So I added code to picture command as follows
string fieldName = ((RadRibbonButton)e.Source).Text;
if (fieldName.ToUpper() == "PICTURE")
{
MergeField mf = new MergeField();
mf.PropertyPath = fieldName;
IncludePictureField picField = new IncludePictureField();
picField.SetPropertyValue(IncludePictureField.ImageUriProperty, mf);
this.radRichTextBox1.InsertField(picField);
}
else
{
radRichTextBox1.InsertField(new MergeField() { PropertyPath = fieldName });
}
this insert image and also label PICTURE as merged field but on form where this rtf file displayed in richtextbox it shows "Cannot display image"
3. Please tell us teleriks proper method to insert image and display on richtextbox (Field merge method).We are new teleriks method.
4. Also When we create Header and footer in Teleriks editor and save file in rtf. When this rtf file loaded again it doesn't shows header and footer .Please tell me reason behind this.
1. We save document by following code
public void ExportContent(string defaultExtension, string filter,IDocumentFormatProvider formatProvider)
{
var saveFileDialog = new SaveFileDialog
{
DefaultExt = defaultExtension,
Filter = filter
};
saveFileDialog.FileName = wordfilepath;
using (var outputStream = saveFileDialog.OpenFile())
{
formatProvider.Export(radRichTextBox1.Document, outputStream);
}
}
2 . Now when we insert picture using teleriks insert picture method .Picture is inserted and file is saved by above method.Then on another form we cannot display this image on richtextbox .So I added code to picture command as follows
string fieldName = ((RadRibbonButton)e.Source).Text;
if (fieldName.ToUpper() == "PICTURE")
{
MergeField mf = new MergeField();
mf.PropertyPath = fieldName;
IncludePictureField picField = new IncludePictureField();
picField.SetPropertyValue(IncludePictureField.ImageUriProperty, mf);
this.radRichTextBox1.InsertField(picField);
}
else
{
radRichTextBox1.InsertField(new MergeField() { PropertyPath = fieldName });
}
this insert image and also label PICTURE as merged field but on form where this rtf file displayed in richtextbox it shows "Cannot display image"
3. Please tell us teleriks proper method to insert image and display on richtextbox (Field merge method).We are new teleriks method.
4. Also When we create Header and footer in Teleriks editor and save file in rtf. When this rtf file loaded again it doesn't shows header and footer .Please tell me reason behind this.