LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 206
Default strange vba interaction

hi all!

i have some vba code that is located on the worksheet it refers to, inside
the sub

Private Sub Worksheet_Change(ByVal Target As Range)

what the code basically does is based on the users choice, some decisions
are made as to what goes in the next three adjacent cells (same row,
continuing to the right) and if the users input is further required, the user
is prompted for input.

this code works fine and dandy

in another cell (same row, 2 columns to the left of where the user makes
their choice)

is this code (in B14):

=IF(C14="","",WhatIsLeft(D14,From))

C14 is either off ("") or a number from 1 to 20 (it's a line item number)
D14 is the users choice
From is a named range consisting of a single cell.

this is the code for the function WhatIsLeft(String, String)

Public Function WhatIsLeft(lot As String, warehouse As String)
WhatIsLeft = 64
End Function

64 is just a test value, i haven't written the complete function yet.

after i put the formula in B14, the cells E14,G14 and H14 will not 'update'

i have run the debugger and the Worksheet_Change sub gets triggered, and
gets to a point where the 'From' cell is modified, jumps to the WhatIsLeft
function (which it shouldn't) - and quits.

i can't find an error anywhere.

any ideas there?

hopefully i explained this clear enough.

tia

J

 
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
Curious interaction W/Win Exp. Jim H. Excel Discussion (Misc queries) 6 August 5th 08 09:38 PM
how set up regression for interaction? Arun Excel Discussion (Misc queries) 1 August 28th 06 12:10 PM
... interaction with Word ... Dr. Darrell Excel Discussion (Misc queries) 2 July 21st 05 10:42 PM
Interaction between worksheets teresa Excel Programming 1 December 1st 04 10:22 AM
Web interaction Nigel[_6_] Excel Programming 3 February 20th 04 08:34 AM


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

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"