Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8474375
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T17:36:34+00:00 2026-06-10T17:36:34+00:00

i am working on project using play 2 framework with java. I want to

  • 0

i am working on project using play 2 framework with java. I want to populate a drop down list from a database table. I have this code that gets a list of the items from the database. the code snippet is shown below.

public static Result gestureNames()
  {
  List <GestureClassEntity> gcet = GestureClassEntity.find.all();
  return ok(render(gcet)); 
}

however when i run this code play framework tells me that it cannot find render.

i have tried to modify the code which i have shown below

public static void gestureNames()
  {
  List <GestureClassEntity> gcet = GestureClassEntity.find.all();
  render(gcet); 
}

play tells me again that it cannot use a method returning Unit as an Handler

still struggling to understand the play framework can some kindly help me out. Cos i am working on a project and time is running out.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T17:36:36+00:00Added an answer on June 10, 2026 at 5:36 pm

    Remember previous question? https://stackoverflow.com/a/12180812/1066240

    render() is method of the view, so to use it, you need to specify the view

    public static Result gestureNames(){
        List <GestureClassEntity> gcet = GestureClassEntity.find.all();
        return ok(views.html.gestures.render(gcet));    
    }
    

    app/views/gestures.scala.html

    @(gesturesListFromMyController: List[GestureClassEntity])
    
    @for(gesture <- gesturesListFromMyController){
        <div class="gesture-item">
            <h2>@gesture.name</h2>
            <p>@gesture.description</p>
        </div>
    }
    

    BTW: try to simplify your enigmatic models’ names, your life will be better. Can’t be GestureClassEntity named just as Gesture ???

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a working Play Framework project. I'm using Play Framework version number 1.2.5
Working on a project using Entity Framework (4.3.1.0). I'm trying to figure out how
My team working in a project using Winforms application(c#) & MSSQL 2005 as database.
I am a Java programmer and was working on a project using Hibernate and
I'm working on a little Android project in java, I'm using the webapi of
Greetings, I'm working on a low level programming project and I want to play
I'm working on a playframework project, and we test using scalatest. We also want
I'm working on an iPad project where i have to play short video files
I'm working on a project using Maven as tool. Within the project I have
I am working on a game project using Microsoft XNA framework, although this question

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.