473,467 Members | 1,967 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Initial Screen

I have a Visual C#.Net Windows application. I would like to replace the
initial screen with another screen. Can you tell me how to do this. The
original screen 'Owner-Info', I would use 'MyPetPlaces' which will call
'Owner-Info'.
--
Norm Bohana
Oct 25 '06 #1
7 1421
look in your Program.cs, it has application.run(someform) change someform
for the other one
"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:76**********************************@microsof t.com...
>I have a Visual C#.Net Windows application. I would like to replace the
initial screen with another screen. Can you tell me how to do this. The
original screen 'Owner-Info', I would use 'MyPetPlaces' which will call
'Owner-Info'.
--
Norm Bohana

Oct 25 '06 #2
Daniel, Thanks, the application does not have a 'program.cs'. The
'application.run' is in 'Owner.cs' program. I changed the
application.run(new owner()) to application.run(MyPetPlaces()). It would not
compile

'Error 13 D:\Kennel\Owner-Info\Owner.cs 1246 20 Owner-Info 'Owner_Info.MyPetPlaces' is a 'type' but is used like a 'variable''
"Daniel" wrote:
look in your Program.cs, it has application.run(someform) change someform
for the other one
"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:76**********************************@microsof t.com...
I have a Visual C#.Net Windows application. I would like to replace the
initial screen with another screen. Can you tell me how to do this. The
original screen 'Owner-Info', I would use 'MyPetPlaces' which will call
'Owner-Info'.
--
Norm Bohana


Oct 25 '06 #3
lol look closer.

"application.run(new owner()) to application.run(MyPetPlaces())."

what is the other one missing?

change it to

application.run(new MyPetPlaces());

without the new operator it wont create an instance, hence the compile
error.

And owner.cs/Programme.cs same thing, its still your poijt of entry where
you main method is.
"normb" <no***@discussions.microsoft.comwrote in message
news:54**********************************@microsof t.com...
Daniel, Thanks, the application does not have a 'program.cs'. The
'application.run' is in 'Owner.cs' program. I changed the
application.run(new owner()) to application.run(MyPetPlaces()). It would
not
compile

'Error 13 D:\Kennel\Owner-Info\Owner.cs 1246 20 Owner-Info
'Owner_Info.MyPetPlaces' is a 'type' but is used like a 'variable''
"Daniel" wrote:
>look in your Program.cs, it has application.run(someform) change someform
for the other one
"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:76**********************************@microso ft.com...
>I have a Visual C#.Net Windows application. I would like to replace the
initial screen with another screen. Can you tell me how to do this.
The
original screen 'Owner-Info', I would use 'MyPetPlaces' which will
call
'Owner-Info'.
--
Norm Bohana



Oct 25 '06 #4

"normb" <no***@discussions.microsoft.comwrote in message
news:54**********************************@microsof t.com...
Daniel, Thanks, the application does not have a 'program.cs'. The
'application.run' is in 'Owner.cs' program. I changed the
application.run(new owner()) to application.run(MyPetPlaces()). It would
not
compile

'Error 13 D:\Kennel\Owner-Info\Owner.cs 1246 20 Owner-Info
'Owner_Info.MyPetPlaces' is a 'type' but is used like a 'variable''
"Daniel" wrote:
>look in your Program.cs, it has application.run(someform) change someform
for the other one
"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:76**********************************@microso ft.com...
>I have a Visual C#.Net Windows application. I would like to replace the
initial screen with another screen. Can you tell me how to do this.
The
original screen 'Owner-Info', I would use 'MyPetPlaces' which will
call
'Owner-Info'.
--
Norm Bohana


Replace:

Application.Run(MyPetPlaces())

With:

Application.Run(New MyPetPlaces())

HTH,
Mythran
Oct 25 '06 #5
Daniel, My application does not have a program.cs. this code is in my
'Owner.cs' #endregion

/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
Application.Run(new Owner());
}

I tried changing 'new Owner' to 'new MyPetPlaces' and got complie errors.
Was this the right thing to do?

HELP!!!
--
Norm Bohana
"Daniel" wrote:
look in your Program.cs, it has application.run(someform) change someform
for the other one
"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:76**********************************@microsof t.com...
I have a Visual C#.Net Windows application. I would like to replace the
initial screen with another screen. Can you tell me how to do this. The
original screen 'Owner-Info', I would use 'MyPetPlaces' which will call
'Owner-Info'.
--
Norm Bohana


Oct 26 '06 #6
Hi,

What are the compiler errors?

--
Dave Sexton

"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:54**********************************@microsof t.com...
Daniel, My application does not have a program.cs. this code is in my
'Owner.cs' #endregion

/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
Application.Run(new Owner());
}

I tried changing 'new Owner' to 'new MyPetPlaces' and got complie errors.
Was this the right thing to do?

HELP!!!
--
Norm Bohana
"Daniel" wrote:
>look in your Program.cs, it has application.run(someform) change someform
for the other one
"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:76**********************************@microso ft.com...
>I have a Visual C#.Net Windows application. I would like to replace the
initial screen with another screen. Can you tell me how to do this. The
original screen 'Owner-Info', I would use 'MyPetPlaces' which will call
'Owner-Info'.
--
Norm Bohana



Oct 26 '06 #7
Ok stop worrying about the program.cs. Your MAIN entry point is what
matters, it could be anywhere.

You need to tell us the compiler error. In MyNetPlaces a form for a start?
Below should work.

Also make sure if MyNetSPaces is in a different namespace this is included
via the 'using' operator.

[STAThread]
static void Main()
{
Application.Run(new MyNetPlaces());
}

"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:54**********************************@microsof t.com...
Daniel, My application does not have a program.cs. this code is in my
'Owner.cs' #endregion

/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
Application.Run(new Owner());
}

I tried changing 'new Owner' to 'new MyPetPlaces' and got complie errors.
Was this the right thing to do?

HELP!!!
--
Norm Bohana
"Daniel" wrote:
>look in your Program.cs, it has application.run(someform) change someform
for the other one
"nbohana" <nb*****@discussions.microsoft.comwrote in message
news:76**********************************@microso ft.com...
>I have a Visual C#.Net Windows application. I would like to replace the
initial screen with another screen. Can you tell me how to do this.
The
original screen 'Owner-Info', I would use 'MyPetPlaces' which will
call
'Owner-Info'.
--
Norm Bohana



Oct 26 '06 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: Lyn | last post by:
Hi, Can anyone tell me how the initial value displayed in Combo Box is determined when a form is opened? I am loading the dropdown from one field ("CategoryName") of a table, with "ORDER BY ". ...
12
by: Ian Murphy | last post by:
Hopefully someone else has seen something similar. We are experiencing an odd problem with aspnet, iis6 and w2k3. I have written a small site which works fine during the day. Each morning however...
2
by: Struggling Rod | last post by:
I have a new Windows XP computer with VB6/SP6 installed. I also have an old Windows 98SE computer with VB6/SP6 installed. My old computer has a customized initial IDE screen: The toolbars are the...
2
by: Oenone | last post by:
In VB6 I used to use the Load event of a Form to set its position on the screen (based on wherever the user put the form the last time they used it). This was ideal as it fired before the form...
5
by: Amit | last post by:
Hello, I have a simple search screen, with two drop-downs and a text box. There's also a GridView control that is using a SqlDataSource control to show the matching results. The SqlDataSource uses...
2
by: Rick Shaw | last post by:
Hi, I have a problem with the datagridview not refreshed when the application first appear on the screen. The datagridview display data from a table in the dataset. At the same time, I've added...
23
by: sandy | last post by:
I need (okay, I want) to make a dynamic array of my class 'Directory', within my class Directory (Can you already smell disaster?) Each Directory can have subdirectories so I thought to put these...
3
JamesDC
by: JamesDC | last post by:
Hey all, I've been working with old company databases for the last 2 months now and I'm starting to understand Access a lot more than I did before. There's one thing I can't figure out, whenever...
1
by: rag84dec | last post by:
Hi, I have an asp code which creates a grid or matrics (5 x 5 matrics).Each cell contains a button which will have an initial .The initial will be read from a database. say the database has...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.