The NWC24 message search function searches the management information in the message box, finds those message objects that meet certain specified conditions and then expands the obtained results in an array using a simple procedure.
For example, to obtain four NWC24MsgObj messages in the inbox, use the following process:
|
By doing this, the data corresponding to the message in the inbox is stored in NWC24MsgObj type msgObjArray. The actual number obtained in the array is returned in numStored, specified with the third argument of NWC24SearchMsgs() and the remainder is returned in numRemain. When a numerical value equal to or greater than 1 is returned in numRemain, calling NWC24SearchMsgs() again allows the remaining portion to be obtained in the array. (If called until numRemain becomes zero, all of the messages in the inbox can be obtained.)
NWC24InitSearchConds() must be called to redo obtaining messages from the beginning.
Search can also occur by specifying simple filtering conditions.
|
By doing this, only the Wii messages from the specified Wii number are obtained to the array.
In addition, the following search conditions can currently be specified:
NWC24SetSearchCondMsgBox()
Specifies the message box to be searched.
NWC24SetSearchCondForMenu()
Specifies only items that are displayed on the console menu as the search condition.
NWC24SetSearchCondPublic()
Specifies whether to include Public messages in the search targets.
NWC24SetSearchCondAppId()
Specifies the ID of the application that sent the messages.
NWC24SetSearchCondTag()
Specifies the tag number in the message as a search condition.
Several conditions may be specified. In this case, they are refined using the AND condition. To redo the search with different conditions, be sure to first call NWC24InitSearchConds(). The conditions must all be cleared once.
By default, the Inbox is searched for all messages that can be read by the application and are not Public messages. This includes messages bound for the Message Board and for other applications, which other applications have permission to read.
The following functions are provided as an API for performing message searches.
NWC24InitSearchConds : initializes the search process and clears conditions.
NWC24SetSearchCondMsgBox : Specifies search conditions (message box).
NWC24SetSearchCondForMenu : Specifies search conditions (menu display).
NWC24SetSearchCondPublic: specifies search conditions (public messages)
NWC24SetSearchCondFromAddrId : Specifies search conditions (sender's Wii number).
NWC24SetSearchCondAppId : Specifies search conditions (application ID).
NWC24SetSearchCondTag: specifies search conditions (tag number)
NWC24SearchMsgs : Executes search and stores the results in an array.
For details, see the reference manual for each function.
2007/09/03 Added the NWC24SetSearchCondPublic function.
2007/07/26 Added text about the search for tag numbers.
2007/05/03 Revised omissions (in original Japanese).
2006/09/01 Initial version.
CONFIDENTIAL