Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3
Default VBA routines - help please

Greetings from Norfolk, UK
I am trying to create a 'accounts' routine that allows the user to select
first (A) what they want to do (enter sales, monthly account etc.) then (B)
to select the month that they wish to work on.
I used buttons to select the first (A), then the macro that runs from the
button (common to all three butons) to display the list box (B) to select
the month.
The problem is that I cannot find a way to save the information on which
button has been operated to start the process. The macro that runs from the
button (A) does not connect with the macro that runs FROM the pull down
list - they appear as two distinct routines.

I am runnig Excel 2000 should this be relevant to the solution.
--
Richard.

"I have yet to see any problem, however complicated, which when looked at in
the right way, did not become still more complicated"
Poul Anderson



  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default VBA routines - help please

You have code that is in the "button_activate" section right? Create a
global variable in the workbook code (instead of saying "Dim int as integer"
you would use "Public int as integer") and have that variable set by each
individual buttons' "button_activate" code. When you get to the code for
your pull down list you then read the global variable to see what it was set
to for your if or case statements.

"Richard Wrigley" wrote:

Greetings from Norfolk, UK
I am trying to create a 'accounts' routine that allows the user to select
first (A) what they want to do (enter sales, monthly account etc.) then (B)
to select the month that they wish to work on.
I used buttons to select the first (A), then the macro that runs from the
button (common to all three butons) to display the list box (B) to select
the month.
The problem is that I cannot find a way to save the information on which
button has been operated to start the process. The macro that runs from the
button (A) does not connect with the macro that runs FROM the pull down
list - they appear as two distinct routines.

I am runnig Excel 2000 should this be relevant to the solution.
--
Richard.

"I have yet to see any problem, however complicated, which when looked at in
the right way, did not become still more complicated"
Poul Anderson




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
Assigning events to runtime-created controls - is it possible? BizMark Excel Discussion (Misc queries) 1 November 20th 06 09:36 AM
Excel Statistical Functions and Routines David A. Heiser Excel Worksheet Functions 0 June 3rd 05 05:27 PM
Excel Statistical Functions and Routines David A. Heiser Excel Worksheet Functions 1 June 2nd 05 03:52 AM


All times are GMT +1. The time now is 03:20 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"