Solved

i have a converted c code to vb.net and its giving me problems

Posted on 2006-11-11
2
158 Views
Last Modified: 2010-04-23
   'Public  Sub Exit()
    '        System.Console.WriteLine("Exiting...")
    '        System.Environment.Exit(0)
    '    End Sub

says exit is not valid or something...this is in a modual
how do i fix this???
0
Comment
Question by:Johnny
2 Comments
 
LVL 13

Accepted Solution

by:
iHadi earned 250 total points
ID: 17923951
Hi  Pern
Exit is a keyword used by VB.NET, so it's reserved. you cannot name any method of yours Exit. If you do so the compiler will get confused which method should it execute, the builtin one or your Exit method. Try naming your method to something else like MyExit or CustomExit.
0
 
LVL 4

Assisted Solution

by:darkpriest
darkpriest earned 250 total points
ID: 17923952
So in otherwords :)

'Public  Sub ExitMySub()
    '        System.Console.WriteLine("Exiting...")
    '        System.Environment.Exit(0)
    '    End Sub
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

760 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

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now