For Programmers: Free Programming Magazines  


Home > Archive > Cobol > February 2007 > Re: My First C# (warning - long post)









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: My First C# (warning - long post)
andrewmcdonagh

2007-02-01, 6:55 pm

On Feb 1, 10:31 pm, "Frank Swarbrick" <Frank.Swarbr...@efirstbank.com>
wrote:
> LX-i<lxi0...@netscape.net> 02/01/07 7:51 AM >>>
>
>
>
>
> I'm not sure specifically what you are referring to, but, if we assume the
> above code is something like
> string array[] = new string[10];
> for (int i = 0; i < array.length; i++)
> {
> doSomething(array[i]);
>
> }
>
> You can replace it with
>
> foreach (string s in array)
> {
> doSomething(s);
>
> }
>
> Is that what you're looking for?
>
> http://www.c-sharpcorner.com/Upload...hArrays11142...
> 54AM/WorkingWithArrays.aspx
>
> MF Net Express 5.0 has something similar for COBOL, which I'll post from
> home.
>
> Frank
>
> ---
> Frank Swarbrick
> Senior Developer/Analyst - Mainframe Applications
> FirstBank Data Corporation - Lakewood, CO USA


Good call, the other approach is to use Predicates....

see: http://www.c-sharpcorner.com/UploadFile/vandita/
PredicatesInArray10232006063515AM/PredicatesInArray.aspx

Andrew

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com