+ Start a Discussion
Priya MishraPriya Mishra 

how to insert the record the based on the record type.

Hello All,

I need to insert the record in the custom object based on the record type selected in the vf page. please help me with sample code.

thanks in advance.
srinivas raj 1srinivas raj 1
Just remove the If . It is not required. As you are not setting value to po.recordtypeid so it is blank also you are comparing blank with string having value.

Also add the debugs before if to check values of string.
ghdsports (http://www.ghdsports.org)