Return-Path: Delivered-To: apmail-jakarta-james-user-archive@apache.org Received: (qmail 37605 invoked from network); 8 May 2003 05:01:28 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 8 May 2003 05:01:28 -0000 Received: (qmail 1244 invoked by uid 97); 8 May 2003 05:03:40 -0000 Delivered-To: qmlist-jakarta-archive-james-user@nagoya.betaversion.org Received: (qmail 1233 invoked from network); 8 May 2003 05:03:39 -0000 Received: from daedalus.apache.org (HELO apache.org) (208.185.179.12) by nagoya.betaversion.org with SMTP; 8 May 2003 05:03:39 -0000 Received: (qmail 37417 invoked by uid 500); 8 May 2003 05:01:26 -0000 Mailing-List: contact james-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "James Users List" Reply-To: "James Users List" Delivered-To: mailing list james-user@jakarta.apache.org Received: (qmail 37406 invoked from network); 8 May 2003 05:01:25 -0000 Received: from public-smtp.telkom.net.id (HELO out-mta2.plasa.com) (202.134.0.35) by daedalus.apache.org with SMTP; 8 May 2003 05:01:25 -0000 Received: from sun-fe09 ([192.168.17.25] helo=out-mta2.plasa.com) by out-mta2.plasa.com with esmtp (Exim 4.12) id 19DdX2-0006Nu-00 for james-user@jakarta.apache.org; Thu, 08 May 2003 12:01:24 +0700 Received: from [192.168.17.17] (helo=f1.c.plasa.com) by out-mta2.plasa.com with esmtp (Exim 4.12) id 19DdX1-0004RR-00 for james-user@jakarta.apache.org; Thu, 08 May 2003 12:01:23 +0700 Received: from [192.168.19.110] (HELO b1.c.plasa.com) by f1.c.plasa.com (CommuniGate Pro SMTP 4.0) with ESMTP id 29327971 for james-user@jakarta.apache.org; Thu, 08 May 2003 12:01:01 +0700 Received: from [192.168.17.73] (account ) by b1.c.plasa.com (CommuniGate Pro WebUser 4.0) with HTTP id 2541823 for ; Thu, 08 May 2003 12:01:01 +0700 From: "joni santoso" Subject: Creating/Adding/Changing User (Password) To: "James Users List" X-Mailer: CommuniGate Pro Web Mailer v.4.0 Date: Thu, 08 May 2003 12:01:01 +0700 Message-ID: In-Reply-To: <3EB978F4.2070402@lokitech.com> MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1"; format="flowed" Content-Transfer-Encoding: 8bit X-Scanner: exiscan for exim4 (http://duncanthrax.net/exiscan/) *19DdX1-0004RR-00*Us3oTUaMeIU* X-Bogo-Received-From: 192.168.17.17 X-Bogosity: No, tests=bogofilter, spamicity=0.390211, version=0.12.2 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Hi, I read some postings on the archive about adding users but I still couldn't find some snippets. So I tried coding by myself. I wonder why every time I run the codes it keeps producing error like this : C:\>java test test Exception in thread "main" java.lang.NullPointerException at org.apache.james.mailrepository.AvalonMailRepository.list(AvalonMailR epository.java:385) at test.main(test.java:25) I use win2k advanced server and james 2.1.2. if anyone can share his/her codes about adding/changing users, I would be very thankful. here the codes : import org.apache.james.*; import org.apache.mailet.*; import org.apache.james.userrepository.*; import org.apache.james.remotemanager.*; import org.apache.james.mailrepository.*; import java.util.Iterator; public class test { public static void main(String[] args) { System.out.println("test"); /*try { RemoteManager rm = new RemoteManager() ; rm.initialize(); UsersFileRepository ufr = new UsersFileRepository(); Iterator i = ufr.list(); while (i.hasNext()) { System.out.println(i.next()); } System.out.println("done"); } catch (Exception e) { System.out.println("Error : " + e); } */ AvalonMailRepository amr = new AvalonMailRepository(); Iterator i = amr.list(); while (i.hasNext()) { System.out.println(i.next()); } System.out.println("done"); } } =========================================================================================== "TELKOMNet Instan memberikan diskon 40% untuk akses malam hari dari pukul 23.00 sampai 06.00. Berlaku untuk wilayah Jawa Timur mulai 1 Mei 2003 sampai 30 Juni 2003." =========================================================================================== --------------------------------------------------------------------- To unsubscribe, e-mail: james-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: james-user-help@jakarta.apache.org