You need to sign in to do that
Don't have an account?
rajesh_y
list of documents in visualforce page
hi all this is my code
public class docs
{
list<document> dlist=new list<document>();
public docs()
{for(document d:[select name from document limit 5])
{
dlist.add(d);
}
}
public list<document> getdlist()
{return dlist;}}
i am getting error like.Error: docs Compile Error: Loop variable must be an SObject or list of Document at line 6 column 14
whats wrong in my code please help me
Not a custom controller - any apex class at all named Document in your organization will give you this error.
All Answers
This saved and compiled fine in my dev org.
Do you have a custom class called document in your org?
ni donot have any custom controller with a name document
Not a custom controller - any apex class at all named Document in your organization will give you this error.