I am currently working with an IPhone API which consist of about 40 pages of aspx along with their respective aspx.vb pages. They are all partial classes because the API continues to add other phone platforms to it. Currently I have them residing just in a folder. /API/0.1 and /API/1.0 …
How would I call the functions from those IPhone API classes without having to put them in the App_code?
example: I have a partial class SetTextBroadcast with a function like this
Function BroadcastMessage(ByVal Brodcast_recipient() As net.pmgateway.Recipient, ByVal str_Message As String) As net.pmgateway.Reply
'code here
End Function
How do i use that function in a webform? or do I need to put it in App_Code?
something like this is what i’m looking for.
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim objSetTextBroadCast as new SetTextBroadCast()
End Sub
but i get type “SetTextBroadCast” not defined.
thanks for your help
You could change your web site project into a web application project (in Visual Studio 2008, there’s a convert option in the project’s context menu, be sure to make a backup first). In a web application, you are no longer required to have shared code in
App_Code.Beware though, that there are other subtle differences between these two project types. The following links from MSDN might help: