Ask a Question
Ask Question Login
Corporate Training
  1. Community
  2. Salesforce
  3. Question
Salesforce

can only be used with SObjects, or objects that are Visualforce field component resolvable

Asked by Angela Baker Jul 19, 2021 646 views 1 answer
Share

About this question

I have a VF page that has pageblock table on it which displays data from a list. I am trying to add a field from that list in the pageblock table as a input field but I get the below error for the quantity field. How can I use a field from a list of non sObject as input field ?

can only be used with SObjects, or objects that are Visualforce field component resolvable.

Code : Controller

public class TestController_NWL{ public class OrderProduct{ public String materialNumber {get; set;} public Integer quantity {get; set;} } Public List orderProductsList {get; set;} }

VF Page :

 {!HTMLENCODE(op.materialNumber)} 

 How to resolve error? How do I use Apex inputField correctly?

Your answer

1 Answer

More Salesforce discussions

Learn & Explore

Free tutorials and interview questions from industry experts — learn the skill, then get ready to prove it.

Latest Salesforce Blogs

Guides, tips and career advice on Salesforce from JanBask experts.