Java 您能否限制特定的Android API版本从Google Play商店运行/下载应用程序?

Java 您能否限制特定的Android API版本从Google Play商店运行/下载应用程序?,java,android,google-play,android-manifest,android-version,Java,Android,Google Play,Android Manifest,Android Version,好吧,我正在开发并计划发布的一个应用程序有一个问题,但这个问题只发生在一个版本的android SDK(版本4.1.1 API 16)上 我可以限制android版本4.1.1 API 16下载和运行我的应用程序吗 我知道googlePlay有一个特定的设备列表,但问题的出现是因为操作系统版本,而不是设备,至少从调试来看是这样的 我还知道清单文件中有uses sdk属性: <uses-sdk android:minSdkVersion="integer" android

好吧,我正在开发并计划发布的一个应用程序有一个问题,但这个问题只发生在一个版本的android SDK(版本4.1.1 API 16)上

我可以限制android版本4.1.1 API 16下载和运行我的应用程序吗

我知道googlePlay有一个特定的设备列表,但问题的出现是因为操作系统版本,而不是设备,至少从调试来看是这样的

我还知道清单文件中有uses sdk属性:

<uses-sdk android:minSdkVersion="integer"
          android:targetSdkVersion="integer"
          android:maxSdkVersion="integer" />
使用问题日志进行编辑

在最后一个log语句中,字符串几乎随机更改为完全随机的数字。

您可以阻止应用程序运行。 不,当应用程序位于
minSDKVersion
maxSDKVersion/targetSDKVersion

您可以这样检查:

if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.GINGERBREAD &&         android.os.Build.VERSION.SDK_INT <= android.os.Build.VERSION_CODES.HONEYCOMB) {
 
 // For gingerbread but lesser than HONEYCOMB, show a dialog or something and close the app
 finish();

}

if(android.os.Build.VERSION.SDK_INT>=android.os.Build.VERSION_code.gingerbrand&&android.os.Build.VERSION.SDK_INT所以我遇到的问题是由我使用的
pageTransformer
引起的。
android 4.1.1
真的不喜欢它。我不知道为什么,但我所知道的是如果你在cu上使用pageTransformerstom视图和
ActionBarSherlock
在使用
pageTransformer
向翻页添加动画时,您最好小心。

如何描述该问题?可能有一个解决方案。与Simon一致,这里经常有版本特定的修复方案可以通过
Build.version.SDK\u INT编程触发
,您可能希望找到它,而不是在这里走捷径;)一个修复方案会很好,但我已经尝试了几乎所有的方法…问题是:我有一个自定义按钮的视图,范围从0到10,还有一个文本视图,在单击特定按钮后显示按钮文本。很多时候,当单击按钮时,输入和显示的数字只是随机更改为完全随机的租金编号。示例:TextView显示“1777238”,然后单击“4”将其附加到TextView字符串中,但TextView字符串更改为几乎随机的数字,如“533323455”。非常感谢您的帮助!这听起来很像您的错误,我猜操作系统版本是一个骗局。请发布相关代码。我真的很难想象Android操作系统的错误会如此灾难性,导致您描述的症状。更新了按钮侦听器代码,添加了按钮显示的编号到文本视图。
//button listener for the number buttons. Each button will display a number 1 - 10
//upon clicking the button the number that is displayed on the button will be
//added to what is displayed in the textView
//
//mCurrentWorkingText is the current expression that is being added updated.
View.OnClickListener genericNumberButtonListener = new View.OnClickListener() {

    @Override
    public void onClick(View v) {
    //cast the incoming view to a textView so we can get
    //the text the button displays
        TextView textView = (TextView) v;
        String textFromButton = textView.getText().toString();

        if (mCurrentWorkingText.length() == 0) {
            mWorkingTextView.setText(mWorkingTextView.getText()
                    .toString().concat(textFromButton));
            mCurrentWorkingText = textFromButton;
        } else {
                    // if the working TextView isn't zero we need to
                    // append
                    // the
                    // textFromButton to what is already there.
                    mWorkingTextView.setText(mWorkingTextView.getText()
                            .toString().concat(textFromButton));
                    mCurrentWorkingText = mCurrentWorkingText
                            .concat(textFromButton);


        }
    }
};
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.GINGERBREAD &&         android.os.Build.VERSION.SDK_INT <= android.os.Build.VERSION_CODES.HONEYCOMB) {
 
 // For gingerbread but lesser than HONEYCOMB, show a dialog or something and close the app
 finish();

}