Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Problem with Public Variable value being changed.
Hi,
I am hoping someone will be able to explain and offer a fix for this problem I have with a worksheet I am working on. On the module 1 I declared a public variable RowCount as long. This variable is assigned in the Open function to find the last row of data. I then use it in Sheets1 to add/make changes to values on the specified RowCount Range. My problem is that somehwere Rowcount value changes somehow. I have msgbox's everywhere the Rowcount is modified to keep track of it and I cant find a reason why it changes. The only thing I can think of is that I have another worksheet opened that also has VB code and it might mess up with it, but I dont have any variable called RowCount. So I need to fix this. How can I protect the Rowcount so it only changes where it is supposed to (in this case in the module 1 only) and that it can be used anywhere in that worksheet only (right now it only have one sheet called "tracker") Thanks for the help. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
strange problem with public variable | Excel Programming | |||
Public Variable | Excel Programming | |||
Public variable problem | Excel Programming | |||
Public Variable | Excel Programming | |||
public variable | Excel Programming |