Click here to Skip to main content
15,896,154 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi I am creating windows application, i take 2 forms
now i am design in form 1 and form 2

if i execute form 1 will appear but form2 not appearing

i set the property but there in startup object no forms displaying
what i will do to execute the program
Posted
Updated 4-Apr-14 0:53am
v2

you can change start up page in program.cs file
 
Share this answer
 
Comments
hilbert hussen 4-Apr-14 7:13am    
thanku
vsrikanth87 4-Apr-14 8:28am    
Have you got it ?
add two window forms in your project like Form1 and Form2

make the form1 as a startup form

in Form1 load function call Form2.Show

Public Class Form1

    Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

        Form2.Show()

    End Sub
End Class


in Form2 load function, add the below code to show the forms side by side. i used the form size as 300,300

Public Class Form2

    Private Sub Form2_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

        Me.Location = New Point(Form1.Location.X + Form1.Width + 10, Form1.Location.Y)

    End Sub
End Class
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900