Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is it possible to update a constant? 2

Status
Not open for further replies.

UnsolvedCoding

Technical User
Jul 20, 2011
424
US
I am working on an app that goes between Excel and SQL. The documents all come in Excel and the inital scanning happens in Excel. SQL is used only to store the information stripped from the Excel forms.

Part of what I want to incorporate into the code is a way to see which particular version of a form is used most often and based on frequency of use by our client, scan for those versions of the documents first with the least used being checked last.

Is there a way to update constants after the scan so the correct number of times used is updated?

This isn't a number I can put on an Excel tab for reasons of data being manipulated and it doesn't make sense to put it in SQL because others who don't have SQL rights will be using the program.

Is it possible to update the constant in the code that holds the number of times each version of a form is used without the code having to re-write itself?
 


hi,

If a constant COULD be changed, would it be a constant?

Wouldn't it be a variable?

Why do you need a constant rather than a variable?

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 


you could write the value to a text file.

you could write the value to a cell on a sheet in your workbook.

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
A text file may be the best option assuming all the users are mapped the same.

Perhaps a hidden and protected worksheet will work, however with the manipulation levels that occur thats leaves me with questions about keepign the worksheet hidden and protected.
 


Sheets that have a Visible property value of xlSheetVeryHidden, cannot be seen or changed except with VBA code or in the VB Editor.

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top