Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
TK TK is offline
external usenet poster
 
Posts: 177
Default ListBox Prroblem

Hi:

This formula is in (hidden column G )

=IF(ISNA(VLOOKUP
(A6,Material DataBase!$A$9:$H$100,2,0)),,
VLOOKUP(A6,Material DataBase!$A$9:$H$100,2,0))

This formula is in cell D

=IF(A6 ="","",B6*C6*G6)

A B C D E F G

Item Cost Amount Total

Nails 0.25 10 2.50
Bolts 1.00 8 8.00

A listbox is populated from column A of the
Material Database Worksheet (more of a list)

The user can pick items from the list and as
oblivious from cell Gs formula the price
is then in G and the routine is complete.

All works as expected:
The user can copy, drag down, right click and
pick from list to change items in column A and the
formula works

The problem is if you move (left top corner and drag)
an item in column A the formula fails.

Is there a way to disable the move function?
Is there a way to rewrite the formula?

Any help will be greatly appreciated.

TK


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default ListBox Prroblem

If i want to stabilize and address

for example

=A6

I could do

=Indirect("A6")

since A6 in the second instance is a string rather than a cell reference, it
is never adjusted. This would also make it hard to enter the formula and
drag fill it - so you might want to use code to do it.use a formula to
calculate the address

=offset(indirect("A1"),row()-1,0)

If I understand the question.

--
Regards,
Tom Ogilvy

"TK" wrote in message
...
Hi:

This formula is in (hidden column G )

=IF(ISNA(VLOOKUP
(A6,'Material DataBase'!$A$9:$H$100,2,0)),"",
VLOOKUP(A6,'Material DataBase'!$A$9:$H$100,2,0))

This formula is in cell D

=IF(A6 ="","",B6*C6*G6)

A B C D E F G

Item Cost Amount Total

Nails 0.25 10 2.50
Bolts 1.00 8 8.00

A listbox is populated from column A of the
"Material Database" Worksheet (more of a list)

The user can pick items from the list and as
oblivious from cell G's formula the price
is then in G and the routine is complete.

All works as expected:
The user can copy, drag down, right click and
pick from list to change items in column A and the
formula works

The problem is if you move (left top corner and drag)
an item in column A the formula fails.

Is there a way to disable the move function?
Is there a way to rewrite the formula?

Any help will be greatly appreciated.

TK




  #3   Report Post  
Posted to microsoft.public.excel.programming
TK TK is offline
external usenet poster
 
Posts: 177
Default ListBox Prroblem

Tom

Thank You

=offset(indirect("A1"),row()-1,0)


The above works great as a copy down.

however:
The formula
=IF(A6 ="","",B6*C6*G6)

now displays #NA or #REF if a drag or cut
and paste is used.
I could reference a different column B or C, but
maybe you could suggest an alternative.

Thanks again for the previous.

TK


"Tom Ogilvy" wrote:

If i want to stabilize and address

for example

=A6

I could do

=Indirect("A6")

since A6 in the second instance is a string rather than a cell reference, it
is never adjusted. This would also make it hard to enter the formula and
drag fill it - so you might want to use code to do it.use a formula to
calculate the address

=offset(indirect("A1"),row()-1,0)

If I understand the question.

--
Regards,
Tom Ogilvy

"TK" wrote in message
...
Hi:

This formula is in (hidden column G )

=IF(ISNA(VLOOKUP
(A6,'Material DataBase'!$A$9:$H$100,2,0)),"",
VLOOKUP(A6,'Material DataBase'!$A$9:$H$100,2,0))

This formula is in cell D

=IF(A6 ="","",B6*C6*G6)

A B C D E F G

Item Cost Amount Total

Nails 0.25 10 2.50
Bolts 1.00 8 8.00

A listbox is populated from column A of the
"Material Database" Worksheet (more of a list)

The user can pick items from the list and as
oblivious from cell G's formula the price
is then in G and the routine is complete.

All works as expected:
The user can copy, drag down, right click and
pick from list to change items in column A and the
formula works

The problem is if you move (left top corner and drag)
an item in column A the formula fails.

Is there a way to disable the move function?
Is there a way to rewrite the formula?

Any help will be greatly appreciated.

TK





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
date range prroblem TUNGANA KURMA RAJU Excel Discussion (Misc queries) 1 May 24th 08 09:09 PM
listbox B conditional of input in Listbox A Kim K Excel Discussion (Misc queries) 1 October 31st 06 08:27 PM
Multicolumn Listbox and ordinary listbox Ron_D Excel Programming 0 June 4th 04 08:56 PM
listbox.value not equal to listbox.list(listbox.listindex,0) ARB Excel Programming 0 October 22nd 03 12:46 AM
Is refreshing listbox rowsource in listbox click event possible? Jeremy Gollehon[_2_] Excel Programming 4 September 25th 03 06:45 PM


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