Article View: borland.public.jbuilder.java.language
Article #8701Re: Declaring an Array of Strings?
From: Tor Iver Wilhelmsen
Date: Thu, 08 Mar 2001 08:53
Date: Thu, 08 Mar 2001 08:53
13 lines
1333 bytes
1333 bytes
"Harry Whitehouse" <harry@envmgr.com> writes: > String AddressLine[]; Note that this only declares the reference, it does not assign an actual array to it. > for(int i=0;i<7;i++) > AddressLine[i]= new String; // line 208 Unlike C++ and C#, constructors in Java need a parenthesis also when there are no arguments to the constructor. Also, String doesn't have a no-args constructor, so you need an argument.
Technical Details
Message-ID:
<uu254bq17.fsf@sds.no>Path:
arc1-ca.pugleaf.net!supernews.google.com!sn-xit-03!supernews.com!news-out.usenetserver.com!news-out-sjo.usenetserver.com!news.tele.dk!193.190.198.17!newsfeeds.belnet.be!news.belnet.be!newsfeed00.sul.t-online.de!t-online.de!news1.dtag.de!news.stgl.sel.alcatel.de!news.stgl.sel.alcatel.de!bornews.borland.com!not-for-mailReferences:
<3aa6df5f$1_2@dnews>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f74b3,9324d780b1c839d2 X-Google-Attributes: gidf74b3,public X-Google-ArrivalTime: 2001-03-08 01:16:19 PST Path: arc1-ca.pugleaf.net!supernews.google.com!sn-xit-03!supernews.com!news-out.usenetserver.com!news-out-sjo.usenetserver.com!news.tele.dk!193.190.198.17!newsfeeds.belnet.be!news.belnet.be!newsfeed00.sul.t-online.de!t-online.de!news1.dtag.de!news.stgl.sel.alcatel.de!news.stgl.sel.alcatel.de!bornews.borland.com!not-for-mail From: Tor Iver Wilhelmsen <tor.wilhelmsen@sds.no> Newsgroups: borland.public.jbuilder.java.language Subject: Re: Declaring an Array of Strings? Date: 08 Mar 2001 09:53:08 +0100 Organization: Another Netscape Collabra Server User Lines: 13 Sender: towi@SDSA1761 Message-ID: <uu254bq17.fsf@sds.no> References: <3aa6df5f$1_2@dnews> NNTP-Posting-Host: pc4-252.sds.no X-Newsreader: Gnus v5.5/Emacs 20.3