473,796 Members | 2,429 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

VB Module functions not available in 2005

I have upgraded my ASP.Net/VB solution from 2003 to 2005. In 2003 I had a VB
Module with global functions referenced in virtually all ASP.Net VB modules.
After the upgrade to 2005 the ASP.Net VB code no longer recognizes my global
VB Module functions.

How do I reference the functions in the module?

I have over 25 ASP.Net forms.

Thank you
Jul 28 '06 #1
5 1533
Prefix the method names with the module name.
e.g., YourModule.Your Function instead of YourFunction
--
David Anton
www.tangiblesoftwaresolutions.com
Instant C#: VB to C# converter
Instant VB: C# to VB converter
Instant C++: C#/VB to C++ converter
C# Code Metrics: Quick metrics for C#
"BigJohn" wrote:
I have upgraded my ASP.Net/VB solution from 2003 to 2005. In 2003 I had a VB
Module with global functions referenced in virtually all ASP.Net VB modules.
After the upgrade to 2005 the ASP.Net VB code no longer recognizes my global
VB Module functions.

How do I reference the functions in the module?

I have over 25 ASP.Net forms.

Thank you

Jul 29 '06 #2
Does ModuleName.Func tionName() work?
"BigJohn" <bi*****@newsgr oup.nospamwrote in message
news:5B******** *************** ***********@mic rosoft.com...
>I have upgraded my ASP.Net/VB solution from 2003 to 2005. In 2003 I had a
VB
Module with global functions referenced in virtually all ASP.Net VB
modules.
After the upgrade to 2005 the ASP.Net VB code no longer recognizes my
global
VB Module functions.

How do I reference the functions in the module?

I have over 25 ASP.Net forms.

Thank you


Jul 29 '06 #3
BigJohn,
Is the module in the App_Code folder of your web app?

Is there a namespace in the module?

I am able to put the following in App_Code/UtilityModule.v b and it gets used
by my aspx pages.

Option Strict On
Option Explicit On

Public Module UtilityModule

Public Function IIf(Of T)(ByVal expression As Boolean, ByVal
truePart As T, ByVal falsePart As T) As T
If expression Then
Return truePart
Else
Return falsePart
End If
End Function

End Module

--
Hope this helps
Jay B. Harlow [MVP - Outlook]
..NET Application Architect, Enthusiast, & Evangelist
T.S. Bradley - http://www.tsbradley.net
"BigJohn" <bi*****@newsgr oup.nospamwrote in message
news:5B******** *************** ***********@mic rosoft.com...
|I have upgraded my ASP.Net/VB solution from 2003 to 2005. In 2003 I had a
VB
| Module with global functions referenced in virtually all ASP.Net VB
modules.
| After the upgrade to 2005 the ASP.Net VB code no longer recognizes my
global
| VB Module functions.
|
| How do I reference the functions in the module?
|
| I have over 25 ASP.Net forms.
|
| Thank you
|
|
Jul 30 '06 #4
Thank you Jay. Here is what I found and the correction taken.

In 2003 I had a folder named "GlobalComponen ts" which contained various
function, file and database functions. When I upgraded, these modules
remained in a folder named "GlobalComponen ts". When I moved them to
App_Code, all references functioned fine.
Jul 31 '06 #5
Thanks for the follow up.
--
Hope this helps
Jay B. Harlow [MVP - Outlook]
..NET Application Architect, Enthusiast, & Evangelist
T.S. Bradley - http://www.tsbradley.net
"BigJohn" <bi*****@newsgr oup.nospamwrote in message
news:62******** *************** ***********@mic rosoft.com...
| Thank you Jay. Here is what I found and the correction taken.
|
| In 2003 I had a folder named "GlobalComponen ts" which contained various
| function, file and database functions. When I upgraded, these modules
| remained in a folder named "GlobalComponen ts". When I moved them to
| App_Code, all references functioned fine.
Jul 31 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2602
by: Peter Åstrand | last post by:
There's a new PEP available: PEP 324: popen5 - New POSIX process module A copy is included below. Comments are appreciated. ---- PEP: 324 Title: popen5 - New POSIX process module
8
3868
by: Bo Peng | last post by:
Dear list, I am writing a Python extension module that needs a way to expose pieces of a big C array to python. Currently, I am using NumPy like the following: PyObject* res = PyArray_FromDimsAndData(1, int*dim, PyArray_DOUBLE, char*buf); Users will get a Numeric Array object and can change its values (and actually change the underlying C array).
8
3955
by: Irmen de Jong | last post by:
What would be the best way, if any, to obtain the bytecode for a given loaded module? I can get the source: import inspect import os src = inspect.getsource(os) but there is no ispect.getbytecode() ;-)
2
2008
by: Reid Priedhorsky | last post by:
Dear group, I'd have a class defined in one module, which descends from another class defined in a different module. I'd like the superclass to be able to access objects defined in the first module (given an instance of the first class) without importing it. Example of what I'm looking for: <<<file spam.py>>> class Spam(object):
30
2077
by: Franck PEREZ | last post by:
Hello, I'm developing a small XML marshaller and I'm facing an annoying issue. Here's some sample code: ########### My test application ############ class Foo(object): #The class I'd like to serialize pass
6
3682
by: Bob Alston | last post by:
I am looking for Access reporting add-in that would be easy to use by end users. My key focus is on selection criteria. I am very happy with the Access report writer capabilities. As far as development of reports, it is certainly fine in my book. But for end-users, with little experience or training, it would be nice to have an easy way to handle various selection criteria, perhaps with relatively stock reports. I see easy to use by...
10
1684
by: Tom Plunket | last post by:
I've got a bunch of code that runs under a bunch of unit tests. It'd be really handy if when testing I could supply replacement functionality to verify that the right things get called without those things actually getting called, since frequently those calls take a long time to execute and do things that, well, I don't really want to do. E.g. imagine you've got a routine which takes a filespec, generates a list of files, and copies...
18
2851
by: bearophileHUGS | last post by:
In few minutes I have just written this quite raw class, it lacks doctring (the same of the functions of the heapq module), it may contain bugs still, I haven't tested it much. It's just a simple wrapper around some of the functions of the heapq module (nsmallest and nlargest are missing). Usually I use classes only when I need then, I like functional programming enough, and this class seems to just slow down the functions of the heapq...
12
1820
by: reubendb | last post by:
Hello, I am new to Python. I have the following question / problem. I have a visualization software with command-line interface (CLI), which essentially is a Python (v. 2.5) interpreter with functions added to the global namespace. I would like to keep my own functions in a separate module and then import that module to the main script (that will be executed using the CLI interpreter). The problem is, I cannot access the functions in the...
0
9680
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9528
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10456
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10230
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10174
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9052
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7548
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6788
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
2
3731
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.