Solved

ASP variable help in compiled DLL

Posted on 2004-04-26
10
168 Views
Last Modified: 2010-05-02
Ok, I'm attempting to compile my ASP scripts into a component.

However, I've run into a problem... I have an include file called siteSetting.asp that holds all of the variables specific to that website.  It includes the number of records to display per page, row colors, etc. etc. etc... How can I use those variables within the functions in my compiled DLL?  I can't seem to get it to work, and I haven't a clue as to what to search for!

TIA
0
Comment
Question by:pythaguras
[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
  • 4
  • 2
  • 2
  • +1
10 Comments
 
LVL 7

Expert Comment

by:OHDev2004
ID: 10923522
look try to save those variables in the web.config file instead of using a .ASP file
add this section to your web.config File :

  <appSettings>
    <add key="SqlCommand1.CommandText" value="SELECT * from Employee;" />
    <add key="RecordDisplayPerPage" value="20" />
    <add key="AdminPWD" value="Xzuf11" />
    <add key="AdminTextClr" value="BLUE" />
  </appSettings>

0
 

Author Comment

by:pythaguras
ID: 10923534
I'm using ASP 3.0 not .NET
0
 
LVL 7

Expert Comment

by:OHDev2004
ID: 10923538
sorry ,, :) wrong version wrong guy :P
0
Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

 
LVL 28

Expert Comment

by:AzraSound
ID: 10924778
Create properties in your DLL and pass that values into your DLL from your configuration asp page.
0
 

Author Comment

by:pythaguras
ID: 10924788
I've done that, but is there any other way to do it?  
0
 
LVL 28

Expert Comment

by:AzraSound
ID: 10924817
That would be the best way to approach it.  I can't think of anything more direct.  Other option would be to put these configurations in a database or other like storage that you could then access directly from your ASP pages, or from your DLL.
0
 

Author Comment

by:pythaguras
ID: 10924835
Ok, I've figured out a workaround.

First, I made an entire include that passess all of the values to corresponding properties in the DLL. Then, I made the values for all of those parameters (on the previous include) equal to the values in the ASP page; the constants.  That way, there is only one page that controls the variables for the entire site.  

Thanks guys for all your help and suggestions!
0
 

Author Comment

by:pythaguras
ID: 10999178
Pleaes close this and refund my points.
0
 

Accepted Solution

by:
PashaMod earned 0 total points
ID: 11057716
Closed, 125 points refunded.
PashaMod
Community Support Moderator
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

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

751 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