I have a simple ASPX page with some lines of code to show my MP3 files. I tought it was easy to include MP3 library by just using moduls and installed the feature "MediaGarden" with Audio Player. But whole Orchard V1.2.41 just throws errors after
this is installed. I decided to try to include my lines of code into a page. Can you advice me step-by-step how to get my code working in Orchard?
' We need System.IO namespace to read and write to disc
Partial Class Default2
Protected Sub Page_Load(ByVal sender
ByVal e As System.EventArgs)
' Gets full path to text file, in this example page will read itself
As String = Server.MapPath("data/Audiolist.txt")
' Creates instance of StreamReader class
As StreamReader = New StreamReader(FilePath)
' Finally, loads file to string
As String = sr.ReadToEnd()
Jun 28, 2011 at 12:32 AM
Well, you're not providing any details, such as the error you're seeing so that's hard to say. But in any case, if the code is simple, why don't you just move it into a controller in a custom module?