InitialContext context = new InitialContext();
Object ref = context.lookup("CreateAccount");
createAccount = (CreateAccountEJBRemote) ref;
Account account = new Account();
account.setUsername("Regis Rocha");
account.setFirstname("Regis");
Calendar date = new GregorianCalendar();
date.set(1989, 00, 03);
account.setBirthday(date);
account.setEmail("RegisRocha3@gmail.com");
account.setGender("M");
account.setLastname("Rocha");
account.setMobilephone("982895805");
account.setPassword("webtoolkit");
createAccount.createAccout(account);
} catch (NamingException e) {
e.printStackTrace();
} catch (AccountException e) {