0

我需要这个:

sp_search* sp_search_create (   sp_session *    session,
  const char *  query,
  int   track_offset,
  int   track_count,
  int   album_offset,
  int   album_count,
  int   artist_offset,
  int   artist_count,
  int   playlist_offset,
  int   playlist_count,
  sp_search_type    search_type,
  search_complete_cb *  callback,
  void *    userdata     
)

参数:

[in]    session     Session
[in]    query   Query search string, e.g. 'The Rolling Stones' or 'album:"The Black Album"'
[in]    track_offset    The offset among the tracks of the result
[in]    track_count     The number of tracks to ask for
[in]    album_offset    The offset among the albums of the result
[in]    album_count     The number of albums to ask for
[in]    artist_offset   The offset among the artists of the result
[in]    artist_count    The number of artists to ask for
[in]    playlist_offset     The offset among the playlists of the result
[in]    playlist_count  The number of playlists to ask for
[in]    search_type     Type of search, can be used for suggest searches
[in]    callback    Callback that will be called once the search operation is complete. Pass NULL if you are not interested in this event.
[in]    userdata    Opaque pointer passed to callback

目前我已经尝试过这个:

libspotify.sp_search_create(SessionPtr, "mc hammer", 0, 100, 0, 
  100, 0, 100, 0, 100, sp_search_type.SP_SEARCH_STANDARD, 
  ???, CType(vbNull, IntPtr))

虽然我没有收到错误,但我没有得到任何阿泰斯特的名字......我知道???应该是一种回调,但我不知道如何为此做地址

4

1 回答 1

0

尝试使用:

libspotify.sp_search_create(SessionPtr, "mc hammer", 0, 100, 0, 
  100, 0, 100, 0, 100, sp_search_type.SP_SEARCH_STANDARD, 
  AddressOf MyCallback, CType(vbNull, IntPtr))

MyCallback处理搜索完成的子/函数在哪里:

  Private Sub MyCallback
    ...
  End sub
于 2013-06-29T14:02:29.813 回答