Search
Search titles only
By:
Search titles only
By:
Log in
Register
Search
Search titles only
By:
Search titles only
By:
Menu
Install the app
Install
Forums
New posts
All threads
Latest threads
New posts
Trending threads
Trending
Search forums
What's new
New posts
New ads
New profile posts
Latest activity
Free Ads
Latest reviews
Search ads
Members
Current visitors
New profile posts
Search profile posts
Contact us
Latest ads
Ad icon
Singapore V2ray VPN for Zoom Package Tunneling
hu KANNA
Updated:
Yesterday at 7:34 PM
Ad icon
Gampaha
Thenya Mishel
menuka2000
Updated:
Wednesday at 10:48 PM
Handmade Character Soft Toy Bluey Bingo
anil1961
Updated:
Aug 3, 2026
Colombo
Dahua POE Switch 8 Ports (DH-PFS3010-8ET-65)
hashaz2012
Updated:
Aug 3, 2026
Ad icon
Singapore V2Ray VPN for Tunneling
hu KANNA
Updated:
Jul 31, 2026
Electronics
Vehicles
Property
Search
Reply to thread
Forums
Computers & Internet
Software Development
මගේ රේඩියෝ වීවරය
Get the App
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Message
<blockquote data-quote="visula kavinda" data-source="post: 31471836" data-attributes="member: 577973"><p>Imports System.IO</p><p>Imports System.Net.Http</p><p>Imports System.Windows</p><p></p><p>Public Class Form1</p><p> Structure tag_</p><p> Dim url As String</p><p> Dim site As String</p><p> End Structure</p><p> Sub Add_station(name As String, url As String, site As String)</p><p> Dim item As New ListViewItem</p><p> item.Text = name</p><p> Dim a As tag_</p><p> a.url = url</p><p> a.site = site</p><p> item.Tag = a</p><p> ListView1.Items.Add(item)</p><p> End Sub</p><p> Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load</p><p> Add_station("Neth FM", "<a href="https://cp11.serverse.com/proxy/nethfm/stream" target="_blank">https://cp11.serverse.com/proxy/nethfm/stream</a>", "<a href="https://www.nethfm.lk" target="_blank">https://www.nethfm.lk</a>")</p><p> Add_station("Shree FM", "<a href="https://a3.asurahosting.com/listen/shreefm/radio.mp3" target="_blank">https://a3.asurahosting.com/listen/shreefm/radio.mp3</a>", "<a href="http://www.shreefm.lk" target="_blank">http://www.shreefm.lk</a>")</p><p> Add_station("Swadeshiya Sevaya", "<a href="http://220.247.227.6:8000/Snsstream" target="_blank">http://220.247.227.6:8000/Snsstream</a>", "<a href="https://www.slbc.lk" target="_blank">https://www.slbc.lk</a>")</p><p> Add_station("Sirasa FM", "<a href="https://mbc.thestreamtech.com:8087/index.html" target="_blank">https://mbc.thestreamtech.com:8087/index.html</a>", "<a href="https://sirasafm.lk" target="_blank">https://sirasafm.lk</a>")</p><p> Add_station("Hiru FM", "<a href="https://radio.lotustechnologieslk.net:2020/stream/hirufmgarden" target="_blank">https://radio.lotustechnologieslk.net:2020/stream/hirufmgarden</a>", "<a href="https://www.hirufm.lk" target="_blank">https://www.hirufm.lk</a>")</p><p> Add_station("Shaa FM", "<a href="https://radio.lotustechnologieslk.net:2020/stream/shaafmgarden" target="_blank">https://radio.lotustechnologieslk.net:2020/stream/shaafmgarden</a>", "<a href="https://www.shaafm.lk" target="_blank">https://www.shaafm.lk</a>")</p><p> Add_station("Siyatha FM", "<a href="https://dc02.onlineradio.voaplus.com/siyathafm" target="_blank">https://dc02.onlineradio.voaplus.com/siyathafm</a>", "<a href="https://www.siyathafm.lk" target="_blank">https://www.siyathafm.lk</a>")</p><p> Add_station("FM Derana", "<a href="https://cp12.serverse.com/proxy/fmderana/stream" target="_blank">https://cp12.serverse.com/proxy/fmderana/stream</a>", "<a href="https://www.fmderana.lk" target="_blank">https://www.fmderana.lk</a>")</p><p> Add_station("Lak FM", "<a href="https://r1.comcities.com/proxy/oxmycwll/stream" target="_blank">https://r1.comcities.com/proxy/oxmycwll/stream</a>", "<a href="https://www.lakfm.lk" target="_blank">https://www.lakfm.lk</a>")</p><p> Add_station("Sitha FM", "<a href="https://mytuner-radio.com/radio/sitha-fm-sit-886-432491/" target="_blank">https://mytuner-radio.com/radio/sitha-fm-sit-886-432491/</a>", "")</p><p> Add_station("Ran FM", "<a href="https://a3.asurahosting.com/listen/ranfm/radio.mp3" target="_blank">https://a3.asurahosting.com/listen/ranfm/radio.mp3</a>", "<a href="https://ranfm.lk/" target="_blank">https://ranfm.lk/</a>")</p><p> Add_station("Y FM", "<a href="https://mbc.thestreamtech.com:7032/index.html" target="_blank">https://mbc.thestreamtech.com:7032/index.html</a>", "<a href="https://myy.lk/" target="_blank">https://myy.lk/</a>")</p><p> Add_station("Yes FM", "<a href="https://mbc.thestreamtech.com:7056/index.html/stream" target="_blank">https://mbc.thestreamtech.com:7056/index.html/stream</a>", "<a href="https://yesfmonline.com/" target="_blank">https://yesfmonline.com/</a>")</p><p> Add_station("Gold FM", "<a href="https://radio.lotustechnologieslk.net:8000/;" target="_blank">https://radio.lotustechnologieslk.net:8000/;</a>", "<a href="https://www.goldfm.lk/" target="_blank">https://www.goldfm.lk/</a>")</p><p> Add_station("Rangiri FM", "<a href="https://rangiri.radioca.st/stream?type=http&nocache=112730" target="_blank">https://rangiri.radioca.st/stream?type=http&nocache=112730</a>", "<a href="https://rangirisrilanka.lk/radio/" target="_blank">https://rangirisrilanka.lk/radio/</a>")</p><p> Add_station("SLBC Sinhala National Service", "", "<a href="https://www.slbc.lk" target="_blank">https://www.slbc.lk</a>")</p><p> Add_station("SLBC Welenda Sevaya", "", "<a href="https://www.slbc.lk/world-heritage-sites/welenda-sevaya" target="_blank">https://www.slbc.lk/world-heritage-sites/welenda-sevaya</a>")</p><p> Add_station("City FM", "<a href="http://220.247.227.20:8000/citystream" target="_blank">http://220.247.227.20:8000/citystream</a>", "<a href="https://www.slbc.lk/world-heritage-sites/city-fm" target="_blank">https://www.slbc.lk/world-heritage-sites/city-fm</a>")</p><p> Add_station("Free FM", "<a href="https://stream.zeno.fm/qcpcogj5uvstv" target="_blank">https://stream.zeno.fm/qcpcogj5uvstv</a>", "<a href="https://freefm.lk/player/index.html" target="_blank">https://freefm.lk/player/index.html</a>")</p><p> Add_station("Lakhanda radio", "<a href="https://cp12.serverse.com/proxy/itnfm?mp=/stream" target="_blank">https://cp12.serverse.com/proxy/itnfm?mp=/stream</a>", "<a href="https://lakhandaradio.lk/" target="_blank">https://lakhandaradio.lk/</a>")</p><p> Add_station("WOW Radio", "<a href="https://cp11.serverse.com/proxy/wowradio/stream" target="_blank">https://cp11.serverse.com/proxy/wowradio/stream</a>", "<a href="https://onlineradiobox.com/lk/wowco/?cs=lk.wowco&played=1" target="_blank">https://onlineradiobox.com/lk/wowco/?cs=lk.wowco&played=1</a>")</p><p> Add_station("QFM සිතුල රේඩියෝ", "<a href="https://stream.qfmradio.qa/qfm953" target="_blank">https://stream.qfmradio.qa/qfm953</a>", "<a href="https://qfmradio.qa/station/sithula" target="_blank">https://qfmradio.qa/station/sithula</a>")</p><p> Add_station("Rhythm FM", "<a href="https://dc02.onlineradio.voaplus.com/rhythmfm" target="_blank">https://dc02.onlineradio.voaplus.com/rhythmfm</a>", "<a href="https://rhythmfm.lk/" target="_blank">https://rhythmfm.lk/</a>")</p><p> Add_station("Seth FM", "<a href="https://listen.radioking.com/radio/384487/stream/435781" target="_blank">https://listen.radioking.com/radio/384487/stream/435781</a>", "<a href="https://sethfm.lk/" target="_blank">https://sethfm.lk/</a>")</p><p> Add_station("පැරණි ගී රේඩියෝ", "<a href="http://151.80.42.191:8288/stream" target="_blank">http://151.80.42.191:8288/stream</a>", "<a href="https://radiosindia.com/paranigeeradio.html" target="_blank">https://radiosindia.com/paranigeeradio.html</a>")</p><p> Add_station("Fox FM", "<a href="https://cp11.serverse.com/proxy/foxfm/stream/;stream.mp3" target="_blank">https://cp11.serverse.com/proxy/foxfm/stream/;stream.mp3</a>", "<a href="https://onlineradiobox.com/lk/foxfm/" target="_blank">https://onlineradiobox.com/lk/foxfm/</a>")</p><p> Add_station("Kiss FM", "<a href="https://srv01.onlineradio.voaplus.com/kissfm" target="_blank">https://srv01.onlineradio.voaplus.com/kissfm</a>", "<a href="https://kissfm.lk/" target="_blank">https://kissfm.lk/</a>")</p><p> Add_station("Sitha FM", "<a href="https://shaincast.caster.fm:48148/listen.mp3" target="_blank">https://shaincast.caster.fm:48148/listen.mp3</a>", "<a href="https://x.com/SithaFM" target="_blank">https://x.com/SithaFM</a>")</p><p> Add_station("Rasa FM", "<a href="https://sonic01.instainternet.com/8084/stream&_=1782040347703" target="_blank">https://sonic01.instainternet.com/8084/stream&_=1782040347703</a>", "<a href="https://rasafm.godaddysites.com/" target="_blank">https://rasafm.godaddysites.com/</a>")</p><p></p><p> ' Add_station("ITN", "<a href="https://hls-abiri0ry-livepush.akamaized.net/live_abr_cdn/nsiPyyYPqaaCfd/em0l9G8dNuBQsYh35/tracks-v3a1/rewind-3600.m3u8" target="_blank">https://hls-abiri0ry-livepush.akamaized.net/live_abr_cdn/nsiPyyYPqaaCfd/em0l9G8dNuBQsYh35/tracks-v3a1/rewind-3600.m3u8</a>", "<a href="https://itn.lk/" target="_blank">https://itn.lk/</a>")</p><p> ' Add_station("000", "<a href="https://edge3-moblive.yuppcdn.net/drm1/smil:verbumtvdrm.smil/index.m3u8" target="_blank">https://edge3-moblive.yuppcdn.net/drm1/smil:verbumtvdrm.smil/index.m3u8</a>", "")</p><p> ' Add_station("0000", "<a href="https://jk3lz8xklw79-hls-live.5centscdn.com/live/6226f7cbe59e99a90b5cef6f94f966fd.sdp/playlist.m3u8" target="_blank">https://jk3lz8xklw79-hls-live.5centscdn.com/live/6226f7cbe59e99a90b5cef6f94f966fd.sdp/playlist.m3u8</a>", "")</p><p> ' Add_station("0000", "<a href="https://stream.asiatvnet.com/1/live/master.m3u8" target="_blank">https://stream.asiatvnet.com/1/live/master.m3u8</a>", "")</p><p> 'Add_station("000", "<a href="https://live.peotv.com/bpk-tv/012/output/index.m3u8" target="_blank">https://live.peotv.com/bpk-tv/012/output/index.m3u8</a>", "")</p><p> Add_station("Hiru TV", "<a href="https://tv.hiruhost.com:1936/8012/8012/chunklist_w1355807983.m3u8" target="_blank">https://tv.hiruhost.com:1936/8012/8012/chunklist_w1355807983.m3u8</a>", "")</p><p> ' Add_station("TNL", "<a href="https://stream.castr.com/669ca98e53915ee518fb7a47/live_3b18e370d0f011efa5904f4336ecbf7e/tracks-v1/seg-0-35954.hls.fmp4" target="_blank">https://stream.castr.com/669ca98e53915ee518fb7a47/live_3b18e370d0f011efa5904f4336ecbf7e/tracks-v1/seg-0-35954.hls.fmp4</a>", "")</p><p> ' Add_station("", "<a href="http://66.55.144.67:8104/;stream.mp3" target="_blank">http://66.55.144.67:8104/;stream.mp3</a>", "")</p><p> ' Add_station("", "", "")</p><p></p><p> ' Add_station("", "", "")</p><p> End Sub</p><p> Public Sub PlayRadio(url As String)</p><p> AxWindowsMediaPlayer1.URL = url</p><p> AxWindowsMediaPlayer1.settings.autoStart = True</p><p> End Sub</p><p></p><p> Public Sub StopRadio()</p><p> AxWindowsMediaPlayer1.Ctlcontrols.stop()</p><p> End Sub</p><p></p><p> Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click</p><p> ' PlayRadio("<a href="https://cp11.serverse.com/proxy/nethfm/stream" target="_blank">https://cp11.serverse.com/proxy/nethfm/stream</a>")</p><p> ' PlayRadio("[MEDIA=youtube]isxYZE_aLHI[/MEDIA]") ';stream.mp3")</p><p> ' PlayRadio("<a href="https://nethfm.lk/stream" target="_blank">https://nethfm.lk/stream</a>")</p><p> '<a href="https://cp11.serverse.com/proxy/nethfm/stream" target="_blank">https://cp11.serverse.com/proxy/nethfm/stream</a></p><p> Dim a As tag_</p><p> a = ListView1.SelectedItems(0).Tag</p><p> PlayRadio(a.url)</p><p> End Sub</p><p> Private Sub ListView1_ItemActivate(sender As Object, e As EventArgs) Handles ListView1.ItemActivate</p><p> Dim a As tag_</p><p> a = ListView1.SelectedItems(0).Tag</p><p> PlayRadio(a.url)</p><p> Text = ListView1.SelectedItems(0).Text</p><p> TextBox1.Text = a.site</p><p> Button4.Enabled = True</p><p> End Sub</p><p></p><p></p><p> Private Sub ListView1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ListView1.SelectedIndexChanged</p><p></p><p> End Sub</p><p></p><p> Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click</p><p> StopRadio()</p><p> End Sub</p><p></p><p> Private Sub TextBox1_TextChanged(sender As Object, e As EventArgs) Handles TextBox1.TextChanged</p><p></p><p> End Sub</p><p></p><p> Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click</p><p> Process.Start(New ProcessStartInfo With {.FileName = TextBox1.Text, .UseShellExecute = True})</p><p> End Sub</p><p></p><p> Private Sub AxWindowsMediaPlayer1_Enter(sender As Object, e As EventArgs) Handles AxWindowsMediaPlayer1.Enter</p><p></p><p> End Sub</p><p></p><p> Private Sub Button5_Click(sender As Object, e As EventArgs) Handles Button5.Click</p><p> Button5.Enabled = False</p><p> Dim a As tag_</p><p> a = ListView1.SelectedItems(0).Tag</p><p></p><p> Task.Run(Async Function()</p><p> Await StartRecording(a.url, "D:\Radio\Record.mp3")</p><p> End Function)</p><p> Button6.Enabled = True</p><p> End Sub</p><p> Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click</p><p> Button6.Enabled = False</p><p> If recorderCTS IsNot Nothing Then</p><p> recorderCTS.Cancel()</p><p> End If</p><p> Button5.Enabled = True</p><p> End Sub</p><p> Private recorderCTS As Threading.CancellationTokenSource</p><p></p><p> Private Async Function StartRecording(streamUrl As String, filePath As String) As Task</p><p></p><p> recorderCTS = New Threading.CancellationTokenSource()</p><p></p><p> Using client As New HttpClient()</p><p></p><p> Using netStream = Await client.GetStreamAsync(streamUrl)</p><p></p><p> Using fileStream As New FileStream(filePath, FileMode.Create)</p><p></p><p> Dim buffer(16383) As Byte</p><p></p><p> While Not recorderCTS.IsCancellationRequested</p><p></p><p> Dim bytesRead = Await netStream.ReadAsync(buffer, 0, buffer.Length)</p><p></p><p> If bytesRead <= 0 Then Exit While</p><p></p><p> Await fileStream.WriteAsync(buffer, 0, bytesRead)</p><p></p><p> End While</p><p></p><p> End Using</p><p></p><p> End Using</p><p></p><p> End Using</p><p></p><p> End Function</p><p></p><p></p><p>End Class</p></blockquote><p></p>
[QUOTE="visula kavinda, post: 31471836, member: 577973"] Imports System.IO Imports System.Net.Http Imports System.Windows Public Class Form1 Structure tag_ Dim url As String Dim site As String End Structure Sub Add_station(name As String, url As String, site As String) Dim item As New ListViewItem item.Text = name Dim a As tag_ a.url = url a.site = site item.Tag = a ListView1.Items.Add(item) End Sub Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load Add_station("Neth FM", "[URL]https://cp11.serverse.com/proxy/nethfm/stream[/URL]", "[URL]https://www.nethfm.lk[/URL]") Add_station("Shree FM", "[URL]https://a3.asurahosting.com/listen/shreefm/radio.mp3[/URL]", "[URL]http://www.shreefm.lk[/URL]") Add_station("Swadeshiya Sevaya", "[URL]http://220.247.227.6:8000/Snsstream[/URL]", "[URL]https://www.slbc.lk[/URL]") Add_station("Sirasa FM", "[URL]https://mbc.thestreamtech.com:8087/index.html[/URL]", "[URL]https://sirasafm.lk[/URL]") Add_station("Hiru FM", "[URL]https://radio.lotustechnologieslk.net:2020/stream/hirufmgarden[/URL]", "[URL]https://www.hirufm.lk[/URL]") Add_station("Shaa FM", "[URL]https://radio.lotustechnologieslk.net:2020/stream/shaafmgarden[/URL]", "[URL]https://www.shaafm.lk[/URL]") Add_station("Siyatha FM", "[URL]https://dc02.onlineradio.voaplus.com/siyathafm[/URL]", "[URL]https://www.siyathafm.lk[/URL]") Add_station("FM Derana", "[URL]https://cp12.serverse.com/proxy/fmderana/stream[/URL]", "[URL]https://www.fmderana.lk[/URL]") Add_station("Lak FM", "[URL]https://r1.comcities.com/proxy/oxmycwll/stream[/URL]", "[URL]https://www.lakfm.lk[/URL]") Add_station("Sitha FM", "[URL]https://mytuner-radio.com/radio/sitha-fm-sit-886-432491/[/URL]", "") Add_station("Ran FM", "[URL]https://a3.asurahosting.com/listen/ranfm/radio.mp3[/URL]", "[URL]https://ranfm.lk/[/URL]") Add_station("Y FM", "[URL]https://mbc.thestreamtech.com:7032/index.html[/URL]", "[URL]https://myy.lk/[/URL]") Add_station("Yes FM", "[URL]https://mbc.thestreamtech.com:7056/index.html/stream[/URL]", "[URL]https://yesfmonline.com/[/URL]") Add_station("Gold FM", "[URL]https://radio.lotustechnologieslk.net:8000/;[/URL]", "[URL]https://www.goldfm.lk/[/URL]") Add_station("Rangiri FM", "[URL]https://rangiri.radioca.st/stream?type=http&nocache=112730[/URL]", "[URL]https://rangirisrilanka.lk/radio/[/URL]") Add_station("SLBC Sinhala National Service", "", "[URL]https://www.slbc.lk[/URL]") Add_station("SLBC Welenda Sevaya", "", "[URL]https://www.slbc.lk/world-heritage-sites/welenda-sevaya[/URL]") Add_station("City FM", "[URL]http://220.247.227.20:8000/citystream[/URL]", "[URL]https://www.slbc.lk/world-heritage-sites/city-fm[/URL]") Add_station("Free FM", "[URL]https://stream.zeno.fm/qcpcogj5uvstv[/URL]", "[URL]https://freefm.lk/player/index.html[/URL]") Add_station("Lakhanda radio", "[URL]https://cp12.serverse.com/proxy/itnfm?mp=/stream[/URL]", "[URL]https://lakhandaradio.lk/[/URL]") Add_station("WOW Radio", "[URL]https://cp11.serverse.com/proxy/wowradio/stream[/URL]", "[URL]https://onlineradiobox.com/lk/wowco/?cs=lk.wowco&played=1[/URL]") Add_station("QFM සිතුල රේඩියෝ", "[URL]https://stream.qfmradio.qa/qfm953[/URL]", "[URL]https://qfmradio.qa/station/sithula[/URL]") Add_station("Rhythm FM", "[URL]https://dc02.onlineradio.voaplus.com/rhythmfm[/URL]", "[URL]https://rhythmfm.lk/[/URL]") Add_station("Seth FM", "[URL]https://listen.radioking.com/radio/384487/stream/435781[/URL]", "[URL]https://sethfm.lk/[/URL]") Add_station("පැරණි ගී රේඩියෝ", "[URL]http://151.80.42.191:8288/stream[/URL]", "[URL]https://radiosindia.com/paranigeeradio.html[/URL]") Add_station("Fox FM", "[URL]https://cp11.serverse.com/proxy/foxfm/stream/;stream.mp3[/URL]", "[URL]https://onlineradiobox.com/lk/foxfm/[/URL]") Add_station("Kiss FM", "[URL]https://srv01.onlineradio.voaplus.com/kissfm[/URL]", "[URL]https://kissfm.lk/[/URL]") Add_station("Sitha FM", "[URL]https://shaincast.caster.fm:48148/listen.mp3[/URL]", "[URL]https://x.com/SithaFM[/URL]") Add_station("Rasa FM", "[URL]https://sonic01.instainternet.com/8084/stream&_=1782040347703[/URL]", "[URL]https://rasafm.godaddysites.com/[/URL]") ' Add_station("ITN", "[URL]https://hls-abiri0ry-livepush.akamaized.net/live_abr_cdn/nsiPyyYPqaaCfd/em0l9G8dNuBQsYh35/tracks-v3a1/rewind-3600.m3u8[/URL]", "[URL]https://itn.lk/[/URL]") ' Add_station("000", "[URL]https://edge3-moblive.yuppcdn.net/drm1/smil:verbumtvdrm.smil/index.m3u8[/URL]", "") ' Add_station("0000", "[URL]https://jk3lz8xklw79-hls-live.5centscdn.com/live/6226f7cbe59e99a90b5cef6f94f966fd.sdp/playlist.m3u8[/URL]", "") ' Add_station("0000", "[URL]https://stream.asiatvnet.com/1/live/master.m3u8[/URL]", "") 'Add_station("000", "[URL]https://live.peotv.com/bpk-tv/012/output/index.m3u8[/URL]", "") Add_station("Hiru TV", "[URL]https://tv.hiruhost.com:1936/8012/8012/chunklist_w1355807983.m3u8[/URL]", "") ' Add_station("TNL", "[URL]https://stream.castr.com/669ca98e53915ee518fb7a47/live_3b18e370d0f011efa5904f4336ecbf7e/tracks-v1/seg-0-35954.hls.fmp4[/URL]", "") ' Add_station("", "[URL]http://66.55.144.67:8104/;stream.mp3[/URL]", "") ' Add_station("", "", "") ' Add_station("", "", "") End Sub Public Sub PlayRadio(url As String) AxWindowsMediaPlayer1.URL = url AxWindowsMediaPlayer1.settings.autoStart = True End Sub Public Sub StopRadio() AxWindowsMediaPlayer1.Ctlcontrols.stop() End Sub Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click ' PlayRadio("[URL]https://cp11.serverse.com/proxy/nethfm/stream[/URL]") ' PlayRadio("[MEDIA=youtube]isxYZE_aLHI[/MEDIA]") ';stream.mp3") ' PlayRadio("[URL]https://nethfm.lk/stream[/URL]") '[URL]https://cp11.serverse.com/proxy/nethfm/stream[/URL] Dim a As tag_ a = ListView1.SelectedItems(0).Tag PlayRadio(a.url) End Sub Private Sub ListView1_ItemActivate(sender As Object, e As EventArgs) Handles ListView1.ItemActivate Dim a As tag_ a = ListView1.SelectedItems(0).Tag PlayRadio(a.url) Text = ListView1.SelectedItems(0).Text TextBox1.Text = a.site Button4.Enabled = True End Sub Private Sub ListView1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ListView1.SelectedIndexChanged End Sub Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click StopRadio() End Sub Private Sub TextBox1_TextChanged(sender As Object, e As EventArgs) Handles TextBox1.TextChanged End Sub Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click Process.Start(New ProcessStartInfo With {.FileName = TextBox1.Text, .UseShellExecute = True}) End Sub Private Sub AxWindowsMediaPlayer1_Enter(sender As Object, e As EventArgs) Handles AxWindowsMediaPlayer1.Enter End Sub Private Sub Button5_Click(sender As Object, e As EventArgs) Handles Button5.Click Button5.Enabled = False Dim a As tag_ a = ListView1.SelectedItems(0).Tag Task.Run(Async Function() Await StartRecording(a.url, "D:\Radio\Record.mp3") End Function) Button6.Enabled = True End Sub Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click Button6.Enabled = False If recorderCTS IsNot Nothing Then recorderCTS.Cancel() End If Button5.Enabled = True End Sub Private recorderCTS As Threading.CancellationTokenSource Private Async Function StartRecording(streamUrl As String, filePath As String) As Task recorderCTS = New Threading.CancellationTokenSource() Using client As New HttpClient() Using netStream = Await client.GetStreamAsync(streamUrl) Using fileStream As New FileStream(filePath, FileMode.Create) Dim buffer(16383) As Byte While Not recorderCTS.IsCancellationRequested Dim bytesRead = Await netStream.ReadAsync(buffer, 0, buffer.Length) If bytesRead <= 0 Then Exit While Await fileStream.WriteAsync(buffer, 0, bytesRead) End While End Using End Using End Using End Function End Class [/QUOTE]
Insert quotes…
Verification
Dawasata paya keeyak thibeda?
Post reply
Top
Bottom