小编Aja*_*jay的帖子

Eclipse可执行启动程序无法找到其随播启动程序jar窗口

我正面临一个小问题,需要帮助.

我不得不在笔记本电脑上重新安装Windows.之后我安装了Java,提取了Eclipse并设置了环境变量,即Path到Java bin目录,还创建了一个JAVA_HOME变量并进行设置.每次我尝试打开eclipse.exe时都会出现以下错误.

eclipse可执行程序启动程序无法找到其伴侣启动程序jar.

我在这里错过了什么?

eclipse

64
推荐指数
4
解决办法
27万
查看次数

Android:从计时器线程访问UI元素

public Button stb;
static int cnt=0;
public ArrayList<RadioButton> Butgrp1 = new ArrayList<RadioButton>();
Timer myt; 
TimerTask t;
stb.setOnClickListener(new OnClickListener() {

public void onClick(View v) {

myt.mschedule(new TimerTask() {

    @Override
    public void run() {

        // TODO Auto-generated method stub


        System.out.println("Entering run");
        Handler h=new Handler();

        h.post(new Runnable() {

            public void run() {

                // TODO Auto-generated method stub
                runOnUiThread(new Runnable() {

                    public void run() {
                        // TODO Auto-generated method stub
                        Butgrp1.get(cnt).setChecked(true);
                        cnt=cnt+1;
                        if(cnt>4)
                            cnt=0;
                        if(cnt>0)
                        //  Butgrp1.get(cnt-1).setChecked(false);
                        System.out.println(cnt);
                    }
                });


            }
        });

        //rg.getChildAt(cnt).setPressed(true);

    } …
Run Code Online (Sandbox Code Playgroud)

android timer timertask

21
推荐指数
1
解决办法
3万
查看次数

Android地图:无法在当前主题中找到样式"mapViewStyle"

我试图在我的应用程序中使用地图,我收到此错误,无法在当前主题中找到样式'mapViewStyle'

我已正确生成密钥,并已尝试在其他地方为同一问题提供的所有解决方案.

1.my target api and the one mentioned in the manifest file are the same.
2.There is no import.R in my project
3.I have cleaned my project.
4.Uses-library element is a child of the application.
Run Code Online (Sandbox Code Playgroud)

这是我的xml文件

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical" >

    <com.google.android.maps.MapView
        android:id="@+id/mapview1"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:clickable="true"
        android:apiKey="*****************" 
        android:enabled="true"
        />

</LinearLayout>
Run Code Online (Sandbox Code Playgroud)

这是我对应的java文件

package com.epidemicator.prototype;

import android.os.Bundle;
import com.google.android.maps.MapActivity;

public class Mapacti extends MapActivity {

    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.mapview);
    }

    @Override
    protected boolean isRouteDisplayed() {
        // TODO …
Run Code Online (Sandbox Code Playgroud)

xml android google-maps

6
推荐指数
1
解决办法
3423
查看次数

向localhost发送发布请求

我需要从我的Android设备发送一个http post请求到我的localhost:8080上运行的web服务器,并由google app引擎托管.

目前的代码是这样的:

    try {

                HttpPost httppost = new HttpPost("http://192.168.2.220:8080");
                httppost.setHeader("Content-type", "application/json");
                ResponseHandler <String> responseHandler = new BasicResponseHandler();
                StringEntity se = new StringEntity(object.toString()); 
           se.setContentEncoding(newBasicHeader(HTTP.CONTENT_TYPE,"application/json"));
                httppost.setEntity(se);
                System.out.println("Request Sent");
                String response = httpclient.execute(httppost, responseHandler);

                String temp = EntityUtils.toString(response.getEntity());



            } catch (ClientProtocolException e) {}
            catch (IOException e) {
            }
        }
Run Code Online (Sandbox Code Playgroud)

我也尝试过设置:

    HttpPost httppost = new HttpPost("http://10.0.2.2:8080");
Run Code Online (Sandbox Code Playgroud)

在所有情况下,响应为空并且程序强制关闭.我正确地发送请求了吗?有人可以在这里指导我吗?

谢谢

post android http request

3
推荐指数
1
解决办法
1万
查看次数

在qml中设置网格的ChildrenRect宽度?

我需要知道如何为网格元素设置ChildrenRect的高度和宽度?

 Grid {
             id: grid1
             anchors.fill: parent
             rows: 10
             columns: 10


             childrenRect.height: background.height/10
             childrenRect.width: background.width/10

         }
Run Code Online (Sandbox Code Playgroud)

它说它是一个只读元素,当我尝试这样做时无法改变.

qml

2
推荐指数
1
解决办法
1091
查看次数

标签 统计

android ×3

eclipse ×1

google-maps ×1

http ×1

post ×1

qml ×1

request ×1

timer ×1

timertask ×1

xml ×1