Permission Problem

Put your problem here if it does not fit any of the other categories.

Permission Problem

Postby oaz1 » Fri Jun 04, 2010 10:39 am

Hey,

i started to develop for android and i have the first problem...

i want to send an sms with my app, but everytime it says users xxxxx have no permission to send sms.

i add a in the androidmanifest
<uses-permission android:name="android.permission.SEND_SMS" />

But doesnt work. Or does i need this tag, <uses-permission android:name="android.permission.SEND_SMS"></uses-permission>. Which one is the right?

I m a little bit confussed! :P
oaz1
Freshman
Freshman
 
Posts: 3
Joined: Fri Jun 04, 2010 9:50 am

Top

Re: Permission Problem

Postby anarche » Fri Jun 04, 2010 11:06 am

the first one is correct. where in the manifest did you place the string?
anarche
Master Developer
Master Developer
 
Posts: 369
Joined: Sun Apr 11, 2010 5:21 am

Re: Permission Problem

Postby oaz1 » Fri Jun 04, 2010 11:12 am

Code: Select all
    <application android:icon="@drawable/icon" android:label="@string/app_name" android:permission="android.permission.SEND_SMS" android:debuggable="true">
        <activity android:name=".SMSFlood"
                  android:label="@string/app_name">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
   <uses-permission android:name="android.permission.SEND_SMS" />
    </application>


I placed it one next to last.
oaz1
Freshman
Freshman
 
Posts: 3
Joined: Fri Jun 04, 2010 9:50 am

Re: Permission Problem

Postby oaz1 » Fri Jun 04, 2010 11:42 am

I fixed my problem, the permission should not in the application tag, if i m wrong please correct me!
oaz1
Freshman
Freshman
 
Posts: 3
Joined: Fri Jun 04, 2010 9:50 am

Top

Return to Other Coding-Problems

Who is online

Users browsing this forum: Google [Bot] and 18 guests