ورود

View Full Version : برنامه Ebook و مشکلات زیاد !



AVR programmer
سه شنبه 20 مهر 1395, 16:27 عصر
سلام دوستان عزیز
این یک برنامه Ebook هست که از یک دی وی دی آموزشی گرفتم البته برنامه هنوز اول هاش هست و هنوز کل برنامه رو ننوشتم ولی

همین الان که می زنم (توی android studio) برنامه ران بشه چندتا ارور گنده میده ! لطفا کمکم کنید . ارورها به این ترتیب هستن :

Error:(11) No resource identifier found for attribute 'supportRtl' in package 'android'

Error:(17, 24) No resource found that matches the given name (at 'theme' with value '@style/AppTheme').

Error:Execution failed for task ':app:processDebugResources'.
> com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'F:\Android-sdk\build-tools\23.0.1\aapt.exe'' finished with non-zero exit value 1

و این هم فایل android manifest که موقع ران کردن بازش میکنه و کلی از نوشته هاش قرمز هست :


<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.ebook_1.ebook_1"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
android:minSdkVersion="15"
android:targetSdkVersion="23" />

<application
android:allowBackup="true"
android:icon="@drawable/ebook_launcher"
android:label="@string/app_name"
android:supportRtl="true"
android:supportsRtl="true"
android:theme="@style/AppTheme" >
<activity
android:name="com.example.ebook_1.ebook_1.main_page"
android:label="@string/app_name"
android:theme="@style/AppTheme.NoActionBar" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="com.example.ebook_1.ebook_1.tblOfContent"
android:label="@string/title_activity_tbl_of_content" />
</application>

</manifest>

و ضمنا فایل "R" همه جا علامتش قرمز هست . و توی پوشه ها هر چی گشتم نبود !

این هم فایل جاوا اگه لازم میشه :


package com.example.ebook_1.ebook_1;

import android.app.Activity;
import android.content.Intent;
import android.graphics.Typeface;
import android.net.Uri;
import android.os.Bundle;
import android.support.v7.app.AlertDialog;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.widget.TextView;

public class main_page extends Activity {

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main_page);

getWindow().getDecorView().setLayoutDirection(View .LAYOUT_DIRECTION_RTL);
TextView logo = (TextView)findViewById(R.id.txtLogo);

logo.setTypeface(
Typeface.createFromAsset(
getAssets(),getString(R.string.my_nastaliq_font));

);



}


public void onBtnTblContentClick(View v)
{
Intent i = new Intent(this,tblOfContent.class);
startActivity(i);
}

public void onBtnFavoriteClick(View v)
{

}

public void onBtnSearchClick(View v)
{

}

public void onBtnSettingsClick(View v)
{

}

public void onBtnAboutmeClick(View v)
{
alert_me(getString(R.string.about_me_title),
getString(R.string.about_me_message),true);
}

public void onBtnWebsiteClick(View v)
{
Uri uri = Uri.parse("http://www.irprogram.com");
Intent i = new Intent(Intent.ACTION_VIEW,uri);
startActivity(i);
}

public void onBtnContactmeClick(View v)
{
alert_me(getString(R.string.contact_me_title),
getString(R.string.contact_me_message),true);
}

public void onBtnExitClick(View v)
{
finish();
}

public void alert_me(String title,String message,boolean cacelable)
{
AlertDialog.Builder alert =new AlertDialog.Builder(this);
alert.setCancelable(cacelable);
alert.setTitle(title);
alert.setMessage(message);
alert.create();
alert.show();
}
}



دوستان لطفا کمکم کنید راه دوری نمیره ! :لبخند: