?
Solved

one more question

Posted on 2003-10-22
3
Medium Priority
?
144 Views
Last Modified: 2010-05-03
what's mean by "Sub Main" was not found.
0
Comment
Question by:gegou
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 19

Accepted Solution

by:
Fahad Mukhtar earned 500 total points
ID: 9602053
you are having problems with the start up form
from the projects menu --> Project1 Properties --> Startup object.
select a start up Form from here
and re run the project
0
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 9602058
In the VB IDE, open a project file.  On the menu, click on Project, then select the last item in the list to view the project properties.  (It will say Project1 Properties if the project is called Project1).

On the general tab, there is a place to tell the project where to start code execution.  By default, it is Form1, which means code will start at

Private Sub Form_Load()
    MsgBox "Started from Form_Load()"
End Sub

on Form1.  If you change it to Sub Main then you must have a MODULE with a sub called main in it.

Public Sub Main()
    MsgBox "Started from Main()"
End Sub  

Hope this helps.
0
 
LVL 4

Expert Comment

by:brother7
ID: 9602065
It means that when you tried to compile your project, it couldn't find the subroutine Main.  You should have a Main subroutine, as this is the entry point in console applications.  When this error appears in the Task List, click on it.  You will be given a chance to specify the module/Main location.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses
Course of the Month11 days, 9 hours left to enroll

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question