public class webdev { public class newAP { public Opportunity opp {get;set;} public String role {get; set;} public newAP() { opp = new Opportunity(); } } public List apList {get; set; } {apList = new List(); } public webdev() { apList.add ( new newAP() ); apList.add ( new newAP() ); apList.add ( new newAP() ); } public PageReference savePartnerData() { PageReference opptyPage = new PageReference('http://www.google.com/?newid=' + apList.get(1).opp.AccountId);); return opptyPage ; } public List getRoles() { List options = new List(); PartnerRole[] partnerRole = [Select MasterLabel from PartnerRole where CreatedById <> null]; options.add(new SelectOption('--None--','--None--')); for(Integer i=0;i