Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
Rich Text box Copy command not working in web server
The below code is working well in my local machine, but when I upload and test it in a Windows server 2003 (web server) , it is not merging the document.
1 System.Windows.Forms.RichTextBox rTxt1 = new System.Windows.Forms.RichTextBox();
2 System.Windows.Forms.RichTextBox rTxt2 = new System.Windows.Forms.RichTextBox();
4 if (strWordContent == "")
6 strWordContent = strMyNewWordContent;
7 strFinalWordContent = strWordContent; //Assign the value to the final variable
11 rTxt2.Rtf = strFinalWordContent; //Get the value from the final variable and store it in a 2nd RTF editor
12 strWordContent = strMyNewWordContent;
14 rTxt1.Rtf = strWordContent;
15 string str = rTxt1.Rtf.ToString();
16 int index = str.LastIndexOf('}');
17 string str1 = str.Insert(index, "\page\par
"); //Adding the page break
18 rTxt1.Rtf = str1;
22 rTxt2.Paste(); //Copy and paste it in the second document.
24 strFinalWordContent = rTxt2.Rtf; // Get the content form 2nd RTF to final variable
My Server Details:
Dot Net Version : 3.5
OS : Windows Server 2003
Office Version : MS Office 2003
Platform : ASP.Net with C#
Application Type : Web application
After statement rTxt2.Paste() is excuted , the previous values is presented in the rTxt2. (the copy and paste command is not working)
Please help on this.
Thanks & regards,
0 · ·