Krushh Member
Posts : 11 Join date : 2011-04-17
| Subject: getting procedure from module Wed Jun 29, 2011 6:27 am | |
| i have a module named modConn, and I have a procedure inside named Retrieve. - Code:
-
Module modConn Public Sub Retrieve(ByVal code As String) 'my code goes here End Sub
I'm trying to use that procedure in my index.aspx.vb like this: - Code:
-
Public Partial Class index Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load Retrieve("VB") End Sub End Class
but it won't work. the page said: - Code:
-
Server Error in '/' Application. Compilation Error Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: BC30451: Name 'Retrieve' is not declared.
I declared it! it is right there. infact, i'm able to access procedure retrieve in my header.master.vb, so why it would not work on index.aspx.vb? Any ideas? Thanks. |
|
Axe Member
Posts : 13 Join date : 2011-04-08
| Subject: Re: getting procedure from module Wed Jun 29, 2011 6:28 am | |
| is your Module modConn embedded in a private? |
|