Solved

asp to aspx.vb - includes previously permitted in asp not permitted in aspx.vb - how to ?

Posted on 2009-05-08
2
264 Views
Last Modified: 2013-12-24
in an earlier asp project file I have calls to functions and sub procedures that heretofore were made available via include statements in the following format <!--#include file = "SQLHelp.asp-->

this is no longer legal in the VS 2005 web application project.

I know that I can add the respective asp function or sub that is resident in the above include to the aspx.vb codebehind file - or I think I can - but it is very convenient to be able to add an include and use the tools I need to the respective aspx file I am working with.

Any options consistent with my above thoughts I could use - I heard soemthing about an "include virtual" option - however I have not been able to make that work in the aspx.vb file.

javascript includes within html tags - working okay

looking for advice - clear concise instruction - an example would be good.

thanks if you are willing to help.

G
0
Comment
Question by:gregcis
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 1

Accepted Solution

by:
lizatexp earned 500 total points
ID: 24341393
You could create a vb file called something like Helper.vb and put it under App_Code.

Then in your code behind you just call Helper.Function1 to get things done.


Heler.vb:
 
Public Class Helper
  
  Public Shared Function Function1() As Integer
    ...
  End Function
 
  Public Shared Function Function2() As Integer
    ...
  End Function
 
End Class

Open in new window

0
 

Author Comment

by:gregcis
ID: 24370435
Hi - sorry to not respond to your solution sooner - it actually took me 2 days to understand how to use your "App_Code" reference - it seems to work - I have many more issues to address realtive to my piece of work.  How might I reach you in the future?
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to write a Context Sensitive Help (an online help that is obtained from a specific point in state of software to provide help with that state) ,  first we need to make the file that contains all topics, which are given exclusive IDs. …
There’s a good reason for why it’s called a homepage – it closely resembles that of a physical house and the only real difference is that it’s online. Your website’s homepage is where people come to visit you. It’s the family room of your website wh…
The purpose of this video is to demonstrate how to add AdSense Ads to a WordPress Website, and how to set up WordPress to automatically place Ads in Sidebars. This will be demonstrated using a Windows 8 PC. Log into your AdSense account. : Cli…
The viewer will learn how to dynamically set the form action using jQuery.

724 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question