+ Start a Discussion
Abhishek Singh 88Abhishek Singh 88 

auto populate input field based on another visualforce page's field

i have a record on vf page and i want that same record should autopopulate in inputtext field of another vf page.
PLEASe help me out.
Vasani ParthVasani Parth
Virendra ChouhanVirendra Chouhan
Hi Abhishek,

Are you redircting one page to another after button click?
If yes then pass URL parameter and get them in second vf page.
Abhishek Singh 88Abhishek Singh 88
Hi Virendra Chouhan
Exactly..i have to go through tthe same
Abhishek Singh 88Abhishek Singh 88
Hi Virendra Chouhan
can u guide me how i pass url parameter to another vf page
Virendra ChouhanVirendra Chouhan
Ok So in your source VF page try somthing like:
pagereference pg=new pagereference('/apex/vfpageName?param1='+paramValueVariable);
return pg;
and in your second page's constructor try somthing like:
String paramValue = apexpages.currentpage().getparameters().get('param1');
and also assgin this paramValue to the inputfiled variable.