Re: VisualBasic.Compatabilty . Goto

Robert Lee <[email protected]>
Newsgroups gmane.comp.windows.devel.dotnet.advanced
Message-ID <002101c97fcb$8fe02590$afa070b0$@net>
IIRC, VisualBasic.Compatabilty resides in its own dll, that is not part of
the standard framework (gets installed with VS). It is only designed for
upgrading, and not production. 



-----Original Message-----
From: Discussion of advanced .NET topics.
[mailto:[email protected]] On Behalf Of Davy J
Sent: Monday, January 26, 2009 10:16 AM
To: [email protected]
Subject: [ADVANCED-DOTNET] VisualBasic.Compatabilty . Goto

Dear Ladies and Gentlemen,

  I present for you delectations tonight the one and only GOTO.

         try
                    {
                        int iCnt2 = 1;

                        Common cm = new Common();
                    tryagain:

                        try
                        {
                            oWait.WaitOne();
                            if (!FTPClients.AddFTPClient(ftp))
                            {
                                ScheduleStatus.AddEditSchedule(new
ScheduleInfo(_schedule.scheduleID, "Downloding Waiting " ,
DateTime.Now.ToString(), _schedule.providerName, _schedule.customerName,
_schedule.contractName, ""));
                                oWait.ReleaseMutex();
                                if (cm.WatchAgain(ref iCnt2))
                                {
                                    goto tryagain;

                                }
                            }

The above code is in a C# application that I'm auditing, one of the
developers at some stage has added a reference to VisualBasic.Compatabilty
so that they could use the goto statement, luckly this isn't in a production
environment yet.  Apart from being very very ugly and a huge kludge can
anyone give me some good reasons to remove the VisualBasic.Compatiblity
assembly and as a by product get them to refactor this code?

Thanks.

Dave.

===================================
View archives and manage your subscription(s) at
http://peach.ease.lsoft.com/archives

===================================
View archives and manage your subscription(s) at http://peach.ease.lsoft.com/archives
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.