Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 92
Default Re : Excel VBA with Run to Reset

1. Have attempted to record a macro but in vain.

2. The expected code is one to effect a reset of all (project)
variables such as one to be achieved by clicking Run (drop-down menu)
Reset (in VBA IDE, under regular circumstances).


3. Please share your experience.

4. Regards
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 789
Default Re : Excel VBA with Run to Reset

Hi
No idea at all what you want.
regards
Paul

On Apr 1, 8:18*am, wrote:
1. Have attempted to record *a macro but in vain.

2. The expected code is one to effect a reset of all (project)
variables such as one to be achieved by clicking Run (drop-down menu)

Reset (in VBA IDE, under regular circumstances).


3. Please share your experience.

4. Regards


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 120
Default Re : Excel VBA with Run to Reset

Hi

Try searching this forum for "clear variables" or "reset variable",
you may have more luck.

Personally if you're looking to loop or re-use a process i prefer
initialising the variable to either 0, empty, or null etc at the start
of the procedure before it is populated with data so i never forget to
clear it.

hth

Keith
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 141
Default Re : Excel VBA with Run to Reset

On Apr 1, 3:18*am, wrote:
1. Have attempted to record *a macro but in vain.

2. The expected code is one to effect a reset of all (project)
variables such as one to be achieved by clicking Run (drop-down menu)

Reset (in VBA IDE, under regular circumstances).


3. Please share your experience.

4. Regards


1. That's too bad ... but recorded macros usually are just a first
step to a working macro..
2. ?
3. My experiences are pretty good.
4. Regards right back atcha!

Please re-phrase your question if you'd like better responses!

HTH

C
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 92
Default Re : Excel VBA with Run to Reset

Thank you for all the responses.

1. My case. There are 2 worksheets in the workbook.

2. The worksheets share the same set of macros (those things are meant
to be reusable one way or the other ; that's a good thing to be.
Thanks-giving).

2. Now, Sheet1 would run the macros OK now and again.

3. Then, there comes the turn when Sheet2 should run the macros ......
and there, the macros do not run as expected at the first attempt.

4. But, wait a jiffy ; go to VBE, click Run Reset and return to
Sheet2 again. This time, the macros would run fine, now and again.

5. Until ......, it enters Sheet1's turn to run the macros again.

6. And, you would guess it precisely that ....... wait a jiffy ; go to
VBE, click Run Reset and return to Sheet1 again. Then, the macros
would run fine, now and again.

7. By then, it's clear that switching from one worksheet to another
would behoove Run Reset prior to running the macros thereof.

8. And therefore, it has become desirable to execute Run Reset (such
a mundane task ..... automatically, since Excel is simply good at
alleviating the menial ones) upon switching between the worksheets.

9. And that means that a macro to effect Run Reset can be instituted
under WorkSheet_Activate() in order to offer that much convenience as
desired.

10. Again, Please share your experience.

11. Regards.


  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 141
Default Re : Excel VBA with Run to Reset

On Apr 3, 9:18 pm, wrote:
Thank you for all the responses.

1. My case. There are 2 worksheets in the workbook.

2. The worksheets share the same set of macros (those things are meant
to be reusable one way or the other ; that's a good thing to be.
Thanks-giving).

2. Now, Sheet1 would run the macros OK now and again.

3. Then, there comes the turn when Sheet2 should run the macros ......
and there, the macros do not run as expected at the first attempt.

4. But, wait a jiffy ; go to VBE, click Run Reset and return to
Sheet2 again. This time, the macros would run fine, now and again.

5. Until ......, it enters Sheet1's turn to run the macros again.

6. And, you would guess it precisely that ....... wait a jiffy ; go to
VBE, click Run Reset and return to Sheet1 again. Then, the macros
would run fine, now and again.

7. By then, it's clear that switching from one worksheet to another
would behoove Run Reset prior to running the macros thereof.

8. And therefore, it has become desirable to execute Run Reset (such
a mundane task ..... automatically, since Excel is simply good at
alleviating the menial ones) upon switching between the worksheets.

9. And that means that a macro to effect Run Reset can be instituted
under WorkSheet_Activate() in order to offer that much convenience as
desired.

10. Again, Please share your experience.

11. Regards.


OK, I think I understand a little more what you need now.

Please post the macro you're using, and state where it lives (in a
module, etc...) and how it's called up (a button, worksheet_change,
etc).

If you do that, I think you'll get answers :)

Chris
  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 92
Default Re : Excel VBA with Run to Reset

cht13er Esq,

Thank you for your response.

1. My case. On to more details.

2. The workbook contains 2 worksheets (each of which is a Filtration
Table) plus another worksheet (used to support Sheet1 and Sheet2, much
like a scratch-pad for storing intermediate results of computations).

3. Since Sheet1 and Sheet2 are similar, the following description of
Sheet1 is as much applicable to Sheet2 (needless to say, the code-
behind for each worksheet is identical ; plus, they share the code
posted in the modules).

4. Sheet1 shows a TextBox and a ComboBox (ActiveX Controls).

5. TextBox1 is served by an event handler of DropButtonClick (which is
acting like a Return Key to be clicked upon completing entry of a text
string thereof). This is not a problem item. Thanksgiving indeed.

6. TextBox1's entry is a key based on which a listing would be
generated to populate the Combox1 in a single column (let's keep
things minimal and simple).

7. The ComboBox1 is served by 2 event handlers namely,
7a. DropButtonClick
7b. Change.

8. The DropButtonClick is used to expand and contract the ComboBox1(as
soon as the DropDown debuts). This controls the width of ComboBox1
according to the variable length of the text strings (each of which is
essentially an English word or an expression daisy-chained by a couple
of hyphens, to say the most).

9. The Change event of ComboBox1 (upon a renewed selection of the text
strings thereof) will be followed suit by yet other computations of
the corresponding macros.

10. The pertinent case is the (instantaneous and unpredictable)
interaction of ComboBox1 events (DropButtonClick and Change ; they are
affecting each other incessantly throughout the process).

11. There is then a labyrinth of additional controls being instituted
to tame the given events at bay.

12. As the worksheets are switched from one to another, it behooves
that "Labyrinth of Additional Controls" to be restored to the
"Primordial States" according to VBE's Run Reset.

13. The resultant code is, needless to say, long, windy and
convoluted ; it's at best unbefitting for display in this
neighbourhood.

14. The code works but it requires the menial intervention by VBE's
Run Reset. In this respect, it hurts the Pride of Automation.

15. Regards.
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Reset Excel 2003 Jane Excel Discussion (Misc queries) 1 October 15th 09 06:10 PM
Excel . Reset Button - ?? [email protected] Excel Discussion (Misc queries) 5 March 7th 08 03:37 AM
reset last cell in Excel The Pedagogue Excel Worksheet Functions 1 March 29th 07 09:58 AM
Reset Button in Excel? Jan C. Excel Worksheet Functions 3 July 2nd 05 02:08 AM
Excel bug, variables reset? RB Smissaert Excel Programming 3 July 31st 04 03:19 PM


All times are GMT +1. The time now is 02:00 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"