Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Return statements within the with endwith blocks
Message
From
12/01/2017 15:54:16
 
 
To
12/01/2017 14:43:45
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Database:
MS SQL Server
Miscellaneous
Thread ID:
01646361
Message ID:
01646629
Views:
36
>>>>>>>>With ... Endwith is a feature I never pined for when I switched to .NET
>>>>>>>>.NET's awesome intellisense more than compensates for any additional typing.
>>>>>>>
>>>>>>>Typing is the least of the problems.
>>>>>>
>>>>>>If you saw how I type, you might think differently.
>>>>>
>>>>>Woud you be so kind as to show us a block of .NET code of yours?
>>>>Sure
>>>>
>>>>This is from a menu program
>>>>
>>>>
>>>> private void maintainBillingAddressToolStripMenuItem_Click(object sender, EventArgs e)
>>>>        {
>>>>            if (commonAppDataMethods.IsRoleAuthorized("MAINT04"))
>>>>            {
>>>>
>>>>                >>>>                maintainStoreBillAddressMethods.menuform = this;
>>>>                maintainStoreBillAddressMethods.ShowParent();
>>>>            }
>>>>        }
>>>>
>>>>
>>>>Please note that most of the typing was done by intellisesnse.
>>>
>>>But still... a line with 167 characters for a simple a=createobject("b")? Tsk, tsk...
>>
>>Yes, it's verbose.
>> I could have eliminated "ApplicationMaintenance." with a "using" above, but this is a menu program that references almost a dozen projects and it's more convenient for me to see the project name in the code than look for it elsewhere.
>>Again, I didn't have to type it and once this compiles no one will know that I could have shortened this line.
>
>certainly not a problem if code was write-once only.
>ApplicationMaintenance.MaintainStoreBillAddressMethods maintainStoreBillAddressMethods = new ApplicationMaintenance.MaintainStoreBillAddressMethods();

>And on the opposite of verbosity we've got conciseness of APL which sometimes makes it hard for humans to decipher.
>
>Hrm... with numerous different glyphs used in APL, it's almost like trying to read something like Chinese.


Yes.

"ApplicationMaintenance.MaintainStoreBillAddressMethods maintainStoreBillAddressMethods = new ApplicationMaintenance.MaintainStoreBillAddressMethods();"

could have been written as
a.b c = new a.b();
and before intellisense, with my (non) typing skillls I might have leaned in that direction.
With intellisense, however, there's every reason to make labels as descriptive as possible, and no reason not to.
Anyone who does not go overboard- deserves to.
Malcolm Forbes, Sr.
Previous
Reply
Map
View

Click here to load this message in the networking platform