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 7195761
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T20:38:39+00:00 2026-05-28T20:38:39+00:00

My current code is: for(int i=0;i<jArray.length();i++){ JSONObject json_data = jArray.getJSONObject(i); String b = json_data.getString(examnames);

  • 0

My current code is:

for(int i=0;i<jArray.length();i++){
            JSONObject json_data = jArray.getJSONObject(i);
            String b = json_data.getString("examnames");
            JSONObject getexamnamesobject = new JSONObject(b);
            getexamnames=getexamnamesobject.getString("types");
            TableRow tr = new TableRow(this);
            TextView tv1 = new TextView(this);
            createView(tr,tv1,getexamnames);
            t1.addView(tr);
        }
public void createView(TableRow tr, TextView t, String viewdata) {
        t.setText(viewdata);
        //adjust the porperties of the textView
        t.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT,LayoutParams.WRAP_CONTENT));
        //t.setTextColor(Color.DKGRAY);
        //t.setBackgroundColor(Color.CYAN);
        t.setPadding(20, 0, 0, 0); 
        tr.setPadding(0, 1, 0, 1); 
        //tr.setBackgroundColor(Color.BLACK);
        tr.addView(t); // add TextView to row.
        }

My output for above code is, I’m getting textviews vertically like this:

English
Maths
Science

What must be the change in the above coding to get the horizontal output like this:

English Maths Science

Please help me. This very important for me
Thanks in advance

  • 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-05-28T20:38:40+00:00Added an answer on May 28, 2026 at 8:38 pm

    Set setStretchAllColumns() and setShrinkAllColumns() to the table layout. and make it orientation “horizontal” for the table layout.

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

Sidebar

Related Questions

This is my current code: #include <list> #include <string> using std::string; using std::list; int
I'm running code that sometimes yields this: UInt32 current; int left, right; ... //sometimes
My current code is this: int volume = Alert.getVolume(); // reads 100 Alert.setVolume(0); It
So here's my code int find_h(int i, int j, int current[N+1][N], int goal[N+1][N]) {
Current Code I have two functions as f1::Int->Int->Int f1 a b | a==1 &&
Current Code Hi I have a function like this: jj::[Int]->[Int] jj xs = [x|x<-xs,x
This is my current code: public void copy(String file, String region) throws FileNotFoundException, IOException{
Given the following code : public void insertIntoQueue(float length,int xElement,int yElement,int whichElement) { Dot
Current code: public static void WhoIsOnline(string worldName, WhoIsOnlineReceived callback) { string url = http://www.tibia.com/community/?subtopic=worlds&world=
Here's my current code: public class MallMapActivity extends Activity { private final static String

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.