#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 64
Default Little task

i am after help,

i am trying to make a list for my comboboxes.

the list needs to conatin all data where column "AX" "AY"
and "AZ" are equal to "".

also, this list needs to be updated by all the comboboxes
on the page.

if i take a value from the list, the value needs to be
removed from the list.

Can anyone help??

Thank you,

Robert Couchman
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Little task

So which column does the information in the list come from?

Do you mean that all comboboxes on the sheet need to share the same list and
that if you select an item from any single combobox, it will be removed from
the list of all comboboxes - will that row also be deleted from the sheet.

Are these activeX comboboxes?

--
Regards,
Tom Ogilvy

"Robert Couchman" wrote in message
...
i am after help,

i am trying to make a list for my comboboxes.

the list needs to conatin all data where column "AX" "AY"
and "AZ" are equal to "".

also, this list needs to be updated by all the comboboxes
on the page.

if i take a value from the list, the value needs to be
removed from the list.

Can anyone help??

Thank you,

Robert Couchman



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 64
Default Little task

Hi Tom,

the information needed is as follows,
if it is possible reference from column "A" (but needs to
be hidden)=
first name from column "B"==
last name from column "C"==<END

Yes, i mean all comboboxes need to share the same list!
(if this is possible)

Yes, the data needs to be deleted off of the list,
BUT, NO the data does not need deleting from workbook!

i believe these are activeX comboboxes (the ones used in
VB as a standard combobox button).

Thank you,

Robert Couchman


-----Original Message-----
So which column does the information in the list come

from?

Do you mean that all comboboxes on the sheet need to

share the same list and
that if you select an item from any single combobox, it

will be removed from
the list of all comboboxes - will that row also be

deleted from the sheet.

Are these activeX comboboxes?

--
Regards,
Tom Ogilvy


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Little task

In a general module:
Public Sub AdjustList(cbox As MSForms.ComboBox)
Dim cbox1 As MSForms.ComboBox
Dim obj As OLEObject
Dim idex As Long
On Error GoTo ErrHandler:
If bBlockEvents Then Exit Sub
bBlockEvents = True
idex = cbox.ListIndex
If idex < -1 Then
For Each obj In Worksheets("Sheet1").OLEObjects
If TypeOf obj.Object Is MSForms.ComboBox Then
Set cbox1 = obj.Object
cbox1.ListIndex = -1
cbox1.Value = ""
cbox1.RemoveItem idex
End If
Next
End If
ErrHandler:
bBlockEvents = False
End Sub


in the sheet module of the sheet with the comboboxes:


Private Sub Combobox1_Click()
If bBlockEvents Then Exit Sub
AdjustList ComboBox1
End Sub

Private Sub Combobox2_Click()
If bBlockEvents Then Exit Sub
AdjustList ComboBox2
End Sub

Private Sub Combobox3_Click()
If bBlockEvents Then Exit Sub
AdjustList ComboBox3
End Sub

' one event for each combobox

In the Thisworkbook Module

Private Sub Workbook_Open()
On Error GoTo ErrHandler:
bBlockEvents = True
SetBoxes
ErrHandler:
bBlockEvents = False
End Sub

Each time you open the workbook, the lists will be re intialized and include
what is in columns A, B, C.

--
Regards,
Tom Ogilvy




"Robert Couchman" wrote in message
...
Hi Tom,

the information needed is as follows,
if it is possible reference from column "A" (but needs to
be hidden)=
first name from column "B"==
last name from column "C"==<END

Yes, i mean all comboboxes need to share the same list!
(if this is possible)

Yes, the data needs to be deleted off of the list,
BUT, NO the data does not need deleting from workbook!

i believe these are activeX comboboxes (the ones used in
VB as a standard combobox button).

Thank you,

Robert Couchman


-----Original Message-----
So which column does the information in the list come

from?

Do you mean that all comboboxes on the sheet need to

share the same list and
that if you select an item from any single combobox, it

will be removed from
the list of all comboboxes - will that row also be

deleted from the sheet.

Are these activeX comboboxes?

--
Regards,
Tom Ogilvy




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
Help on a task Dave[_11_] New Users to Excel 5 January 26th 10 10:28 PM
task scheduler Big Jim New Users to Excel 0 June 1st 06 07:00 PM
First ever task LIGHT USER Excel Discussion (Misc queries) 4 March 23rd 06 09:25 PM
Task bar PghPatti Excel Discussion (Misc queries) 4 February 13th 05 02:05 AM
Task ID for App Quartz Excel Programming 0 December 29th 03 06:31 PM


All times are GMT +1. The time now is 09:07 AM.

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

About Us

"It's about Microsoft Excel"