473,396 Members | 2,004 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

showing Windows form from code module.

Ram
I have a code module with main as subroutine name.
How to launch a Windows form from here.
Thanks,
Ram

Nov 20 '05 #1
4 1565
Here's the code you need. In .NET you need to use Application.Run to ensure
the form stays alive after the Sub Main completes

Public Sub Main()
Dim frm as New Form1()
Application.Run(frm)
End Sub

--
Rob Windsor [MVP-VB]
G6 Consulting
Toronto, Canada
"Ram" <Ra********@hotmail.com> wrote in message
news:OU**************@tk2msftngp13.phx.gbl...
I have a code module with main as subroutine name.
How to launch a Windows form from here.
Thanks,
Ram

Nov 20 '05 #2
Here's the code you need. In .NET you need to use Application.Run to ensure
the form stays alive after the Sub Main completes

Public Sub Main()
Dim frm as New Form1()
Application.Run(frm)
End Sub

--
Rob Windsor [MVP-VB]
G6 Consulting
Toronto, Canada
"Ram" <Ra********@hotmail.com> wrote in message
news:OU**************@tk2msftngp13.phx.gbl...
I have a code module with main as subroutine name.
How to launch a Windows form from here.
Thanks,
Ram

Nov 20 '05 #3
Ram
THANKS

"Rob Windsor [MVP]" <rw******@NO.MORE.SPAM.bigfoot.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
Here's the code you need. In .NET you need to use Application.Run to ensure the form stays alive after the Sub Main completes

Public Sub Main()
Dim frm as New Form1()
Application.Run(frm)
End Sub

--
Rob Windsor [MVP-VB]
G6 Consulting
Toronto, Canada
"Ram" <Ra********@hotmail.com> wrote in message
news:OU**************@tk2msftngp13.phx.gbl...
I have a code module with main as subroutine name.
How to launch a Windows form from here.
Thanks,
Ram


Nov 20 '05 #4
Ram
THANKS

"Rob Windsor [MVP]" <rw******@NO.MORE.SPAM.bigfoot.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
Here's the code you need. In .NET you need to use Application.Run to ensure the form stays alive after the Sub Main completes

Public Sub Main()
Dim frm as New Form1()
Application.Run(frm)
End Sub

--
Rob Windsor [MVP-VB]
G6 Consulting
Toronto, Canada
"Ram" <Ra********@hotmail.com> wrote in message
news:OU**************@tk2msftngp13.phx.gbl...
I have a code module with main as subroutine name.
How to launch a Windows form from here.
Thanks,
Ram


Nov 20 '05 #5

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

Similar topics

4
by: Gerry Viator | last post by:
Hi all, Whats going on. Testing messagebox, text isn't showing up. Public Class Form1 Inherits System.Windows.Forms.Form #Region " Windows Form Designer generated code "
1
by: Gordon Sanderson | last post by:
I have been working with for two days on a database with no problems(changing forms and adding code to the forms and a module). Shut down last night was fine, with no errors generated. This...
1
by: Henry | last post by:
I was trying to work through the Lab 2 exercises in the Microsoft's Windows-Based Applications in Visual C#. While I am not showing any errors I am also not seeing the mainMenu object when I run...
4
by: Ram | last post by:
I have a code module with main as subroutine name. How to launch a Windows form from here. Thanks, Ram
17
by: Jon B | last post by:
Hi All! I have a ASP.NET 2.0 site that works on the Windows 2000 Server. However, when I tried to view this site on my local Windows XP machine, I get "Server Unavailable". If I switch the...
2
pablojoshua
by: pablojoshua | last post by:
Ok I have the current processes showing, but it shows the path of the process too. I just want the list to show the .exe or .dll name with the suffix. This is what I have so far (from microsoft) ...
6
by: painkiller | last post by:
language: vb.net environment: windows forms .net : v1.1 i am having a checkedlistbox control that display document category such as text, image, video, audio etc. these values are coming from...
7
by: Jwe | last post by:
Hi, I've written a program which has both a command line interface and Windows form interface, however it isn't quite working correctly. When run from command line with no arguments it should...
2
by: koosh34 | last post by:
VS2005 VB.net 2.0 I have a form called options with a ListBox1 on it, to fill the list box from several events on the form I put the code to update the ListBox1 items into a sub in a separate code...
16
by: John | last post by:
I am looking for VBA code that will work with Access 2003 to enable dragging and dropping a file/folder name from Windows XP Explorer into an Access form's text box. This is a common functionality...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
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,...

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.