Quantcast
Channel: Appcelerator Developer Center Q&A Unanswered Questions 20
Viewing all articles
Browse latest Browse all 8068

Calendar Event - Change title

$
0
0

i am having some problems with changing the title of calendar events.

evento = calendario.getEventById(idEvento);            
if(evento!= null){
      // here the title is showed correctly, so, the ID is correct.
      Ti.API.info("*** Evento: " + evento.getTitle() ); 
      evento.setTitle("new title of the event");
}
the result is:
[INFO] :   *** Evento: aaaaaaaaa
[ERROR] :  TiExceptionHandler: (main) [23179,23179] ----- Titanium Javascript Runtime Error -----
[ERROR] :  TiExceptionHandler: (main) [0,23179] - In src/favoritos.js:177,22
[ERROR] :  TiExceptionHandler: (main) [2,23181] - Message: Uncaught TypeError: Object #<Event> has no method 'setTitle'
[ERROR] :  TiExceptionHandler: (main) [1,23182] - Source:               evento.setTitle("new title of the event");
[ERROR] :  V8Exception: Exception occurred at src/favoritos.js:177: Uncaught TypeError: Object #<Event> has no method 'setTitle'
SDK: 3.4.1GA i am trying this in a device Motorola with Android 4.4.4

and i have the correct permissions in the tiapp.xml (my app create the event aaaaaaaaa)

<uses-permission android:name="android.permission.READ_CALENDAR"/>
<uses-permission android:name="android.permission.WRITE_CALENDAR"/>
Thanks in advance..

Viewing all articles
Browse latest Browse all 8068

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>