Jump to content

How to get ALL live tv channels in .Net


pünktchen

Recommended Posts

pünktchen

How can i get all live tv channels, no matter if they are from a live tv plugin or from the internal tv engine, as a result of type "ChannelInfo"?
I know how to get the channels by querying the ILibraryManager, but that returns BaseItem and BaseItem has no channel number!
But the channel number is what i'm really after here.

Link to comment
Share on other sites

Have you tried casting the resulting items to LiveTvChannel? From there you can get additional properties such as the Number property.

Link to comment
Share on other sites

pünktchen
LiveTvChannel target = (LiveTvChannel)source;

Never thought of such a simple thing like casting and LiveTvChannel instead of ChannelInfo. Working. Thanks!

Edited by pünktchen
  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...