Click here to Skip to main content
15,921,837 members
Home / Discussions / C#
   

C#

 
Questioni want find a list of form of my application in code? Pin
combo_ci19-Apr-08 6:00
combo_ci19-Apr-08 6:00 
AnswerRe: i want find a list of form of my application in code? Pin
Gareth H19-Apr-08 6:17
Gareth H19-Apr-08 6:17 
GeneralRe: i want find a list of form of my application in code? Pin
combo_ci19-Apr-08 6:19
combo_ci19-Apr-08 6:19 
GeneralRe: i want find a list of form of my application in code? Pin
Spacix One19-Apr-08 6:44
Spacix One19-Apr-08 6:44 
GeneralRe: i want find a list of form of my application in code? Pin
combo_ci19-Apr-08 6:59
combo_ci19-Apr-08 6:59 
GeneralRe: i want find a list of form of my application in code? Pin
Luc Pattyn19-Apr-08 7:45
sitebuilderLuc Pattyn19-Apr-08 7:45 
AnswerRe: i want find a list of form of my application in code? Pin
darkelv19-Apr-08 7:45
darkelv19-Apr-08 7:45 
GeneralUsing Visio Drawing Control 2003 with System.Windows.Forms.RichTextBox Pin
Abisodun19-Apr-08 3:50
Abisodun19-Apr-08 3:50 
I'm having difficulty using the Visio Drawing Control 2003 and the RichTextBox anywhere in the same application.

e.g.

public partial class VisForm : Form<br />
    {<br />
        public VisForm()<br />
        {<br />
            //RichTextBox rttb = new RichTextBox();<br />
            //string rtf = rttb.Rtf;<br />
            //rttb.SelectedRtf = @"{\rtf1\ansi " + "Visible" + @"{\v " + "Hidden" + @"}}";<br />
            //string rtfText = rttb.Text;<br />
<br />
            InitializeComponent();<br />
<br />
            RichTextBox rttb1 = new RichTextBox();<br />
            string rtf1 = rttb1.Rtf;<br />
            rttb1.SelectedRtf = @"{\rtf1\ansi " + "Visible" + @"{\v " + "Hidden" + @"}}";<br />
            string rtfText1 = rttb1.Text;<br />
<br />
        }<br />
<br />
---<br />
}


First Scenario:
Initialize the RichTextBox BEFORE the Visio Drawing Control. Set rttb.SelectedRtf = @"{\rtf1\ansi " + "Visible" + @"{\v " + "Hidden" + @"}}";

rttb.Text will then be "VisibleHidden" which is correct. With the form displayed press CTRL+F to display the Find Dialog. The result is an AccessViolationException with the following message: "Attempted to read or write protected memory. This is often an indication that other memory is corrupt".

Second Scenario:
Initialize the RichTextBox AFTER the Visio Drawing Control. Set rttb.SelectedRtf = @"{\rtf1\ansi " + "Visible" + @"{\v " + "Hidden" + @"}}";

rttb.Text will then be "Visible" which is WRONG. i.e. the hidden text does not get set when the Visio Control is initialized before the RichTextBox. With the form displayed, this time pressing CTRL+F results in the Find Dialog being displayed with no problem.

Any ideas?

Thanks,

B.
Generallambda expression or other default query attribute Pin
AndrusM19-Apr-08 3:17
AndrusM19-Apr-08 3:17 
GeneralRe: lambda expression or other default query attribute Pin
Guffa19-Apr-08 4:11
Guffa19-Apr-08 4:11 
GeneralRe: lambda expression or other default query attribute Pin
AndrusM19-Apr-08 11:02
AndrusM19-Apr-08 11:02 
GeneralRe: lambda expression or other default query attribute Pin
Roger Alsing19-Apr-08 11:43
Roger Alsing19-Apr-08 11:43 
GeneralRe: lambda expression or other default query attribute Pin
Guffa19-Apr-08 13:45
Guffa19-Apr-08 13:45 
GeneralRe: lambda expression or other default query attribute Pin
Roger Alsing20-Apr-08 4:01
Roger Alsing20-Apr-08 4:01 
GeneralRe: lambda expression or other default query attribute Pin
Guffa20-Apr-08 11:05
Guffa20-Apr-08 11:05 
Generalimport a txt file into MSAccess database and later into SQL server database using C# Code Pin
new2pgrmg19-Apr-08 3:06
new2pgrmg19-Apr-08 3:06 
GeneralRe: import a txt file into MSAccess database and later into SQL server database using C# Code Pin
Spacix One19-Apr-08 4:31
Spacix One19-Apr-08 4:31 
GeneralIntPtr Pin
George_George19-Apr-08 2:20
George_George19-Apr-08 2:20 
GeneralRe: IntPtr Pin
Zoltan Balazs19-Apr-08 2:24
Zoltan Balazs19-Apr-08 2:24 
GeneralRe: IntPtr Pin
George_George19-Apr-08 2:31
George_George19-Apr-08 2:31 
GeneralRe: IntPtr Pin
Zoltan Balazs19-Apr-08 2:44
Zoltan Balazs19-Apr-08 2:44 
GeneralRe: IntPtr Pin
George_George19-Apr-08 2:49
George_George19-Apr-08 2:49 
GeneralRe: IntPtr Pin
Zoltan Balazs19-Apr-08 2:58
Zoltan Balazs19-Apr-08 2:58 
GeneralRe: IntPtr Pin
George_George19-Apr-08 3:11
George_George19-Apr-08 3:11 
GeneralRe: IntPtr Pin
Luc Pattyn19-Apr-08 7:48
sitebuilderLuc Pattyn19-Apr-08 7:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.