WoW:API CalendarEventInvite: Difference between revisions

From AddOn Studio
Jump to navigation Jump to search
(New page: {{wowapi}} :Add's a player to the currently opened event. CalendarEventInvite("player") == Parameters == === Arguments === :("player") :;player : String - The name of the player to be...)
 
(Updated with new information)
Line 15: Line 15:


== Details ==
== Details ==
: Appearently, this function seems NOT to work within an addon. The following code, does not result in a proper invite:
: This call must be made from within an Event editing session (ie between the New() and Add() calls or between Open() and Update() calls):
<code>
<code>
  function MyCreateEvent()
  function MyCreateEvent()
Line 23: Line 23:
   CalendarEventSetDate( 1,11,2008)
   CalendarEventSetDate( 1,11,2008)
   CalendarEventSetTime( 20,00)
   CalendarEventSetTime( 20,00)
  CalendarEventInvite( player )
   CalendarAddEvent() -- Save the Event
   CalendarAddEvent() -- Save the Event
  CalendarEventInvite( player )  -- < This does not work
  end
  end
</code>
</code>
 
Inviting a player who is already on the invitation list will result in a "<Player> has already been invited." dialog box appearing.
----
----
__NOTOC__
__NOTOC__

Revision as of 06:10, 7 November 2008

WoW API < CalendarEventInvite

Add's a player to the currently opened event.
CalendarEventInvite("player")

Parameters

Arguments

("player")
player
String - The name of the player to be invited to the event

Returns

nil

Details

This call must be made from within an Event editing session (ie between the New() and Add() calls or between Open() and Update() calls):

function MyCreateEvent()
 CalendarNewEvent() -- Create a new Event
 CalendarEventSetDescription( "description" )
 CalendarEventSetTitle ("title")
 CalendarEventSetDate( 1,11,2008)
 CalendarEventSetTime( 20,00)
 CalendarEventInvite( player )
 CalendarAddEvent() -- Save the Event
end

Inviting a player who is already on the invitation list will result in a "<Player> has already been invited." dialog box appearing.