NekoManu Posted October 25, 2004 Posted October 25, 2004 I have a project with myForm. This form is based on a form and uses the icon of the parent form. I also have a project soReport. In this Project I want to create a form based om myForm. In my application I do the following: myForm dlgMyForm = new myForm(); dlgMyForm.showDialog(); When I run the application I get a warning that there is no user code and such, and the code in myForm does NOT work. Can anyone explain to me what I'm doing wrong and how it should be done? Quote
techmanbd Posted October 25, 2004 Posted October 25, 2004 Not sure if this is what you want but try this dim frm as new myform frm.showdialog() Quote Live as if you were to die tomorrow. Learn as if you were to live forever. Gandhi
NekoManu Posted October 26, 2004 Author Posted October 26, 2004 That works if my form is in the same project as the rest. What I want to do is create a form in a separate project and then call it from another project. Quote
Joe Mamma Posted October 26, 2004 Posted October 26, 2004 That works if my form is in the same project as the rest. What I want to do is create a form in a separate project and then call it from another project. add the forms project to the referneces and then import in your module Quote Joe Mamma Amendment 4: The right of the people to be secure in their persons, houses, papers, and effects, against unreasonable searches and seizures, shall not be violated, and no warrants shall issue, but upon probable cause, supported by oath or affirmation, and particularly describing the place to be searched, and the persons or things to be seized. Amendment 9: The enumeration in the Constitution, of certain rights, shall not be construed to deny or disparage others retained by the people.
NekoManu Posted October 26, 2004 Author Posted October 26, 2004 I did add the project to the references and added the project to my solution, but when I call the form, the code is not executed. Quote
Joe Mamma Posted October 26, 2004 Posted October 26, 2004 I did add the project to the references and added the project to my solution' date=' but when I call the form, the code is not executed.[/quote']are you using vb or c#? Quote Joe Mamma Amendment 4: The right of the people to be secure in their persons, houses, papers, and effects, against unreasonable searches and seizures, shall not be violated, and no warrants shall issue, but upon probable cause, supported by oath or affirmation, and particularly describing the place to be searched, and the persons or things to be seized. Amendment 9: The enumeration in the Constitution, of certain rights, shall not be construed to deny or disparage others retained by the people.
NekoManu Posted October 26, 2004 Author Posted October 26, 2004 I think it is working now. There must have been something wrong with the references. Thank you. Quote
NekoManu Posted October 26, 2004 Author Posted October 26, 2004 The thing is that it works when I open it (the project) in the solution in which the baser form is. If I open the project in a different solution it does not work. Very strange, but then again it is Microsoft Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.