Thread: WEND in VBA
View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Dana DeLouis Dana DeLouis is offline
external usenet poster
 
Posts: 947
Default WEND in VBA

While Abs(kw - Price) 0.00005

As a side note, it is a little unusual here because both kw & Price do not
get changed in the loop.
It appears it could cause an endless loop.
Usually, one or both get change in the loop so that eventually kw-Price
falls below .00005.

--
Dana DeLouis
Windows XP & Office 2007


"Dave F" wrote in message
...
Very helpful, thanks.

Dave
--
A hint to posters: Specific, detailed questions are more likely to be
answered than questions that provide no detail about your problem.


"Jim Thomlinson" wrote:

While...Wend is just one of the control flow structures. I personally
prefer
Do...Loop but there is nothing wrong with While...Wend. Check out this
link
on the different control flow structures...

http://msdn.microsoft.com/library/de...7ecff00da4.asp
--
HTH...

Jim Thomlinson


"Dave F" wrote:

What does WEND mean in VBA code, e.g.:

While Abs(kw - Price) 0.00005
T3 = T1 + (Price - k1) * (T2 - T1) / (k2 - k1)
T1 = T2
k1 = k2
T2 = T3
k2 = (-Application.PV(T2, n, Cpn, 100) + Cpn) / (1 + t)
^ t
- sz
Wend

Does it merely mean While End, sort of like End If?

Dave
--
A hint to posters: Specific, detailed questions are more likely to be
answered than questions that provide no detail about your problem.



 
ExcelBanter Database Error
Database Error Database error
The ExcelBanter database has encountered a problem.

Please try the following:
  • Load the page again by clicking the Refresh button in your web browser.
  • Open the www.excelbanter.com home page, then try to open another page.
  • Click the Back button to try another link.
The www.excelbanter.com forum technical staff have been notified of the error, though you may contact them if the problem persists.
 
We apologise for any inconvenience.