473,395 Members | 1,454 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Got this error when I use "loop until" in the same module

Till here the info gotten is ok

Loop Until strainfo = ""
ScreenMNS.WaitHostQuiet (400)

Second process

Copy "B" & paste in "E"

Range("B2:B600").Select
Selection.Copy
Range("E2").Select
ActiveSheet.Paste
Selection.Replace What:=" ", Replacement:="", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False




then I want to star other process from E2 and the error is on the next loop until

it say´s
" loop without do


this is what I just add


Loop Until strcontrol = ""
ScreenMNS.WaitHostQuiet (400)
Feb 13 '08 #1
2 1457
kadghar
1,295 Expert 1GB
Till here the info gotten is ok


" loop without do


this is what I just add


Loop Until strcontrol = ""
ScreenMNS.WaitHostQuiet (400)
LOOP is for closing DO, e.g.

Expand|Select|Wrap|Line Numbers
  1. dim i as long
  2. dim j as long
  3. i=1
  4. do 
  5.     j = j+i
  6.     i = i+1
  7. loop until i > 10
this will make j = 55 (the sum from 1 to 10)

HTH
Feb 13 '08 #2
Killer42
8,435 Expert 8TB
Yes, the Loop statement goes at the end of a loop, not the start.
Feb 14 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

11
by: Wayne Folta | last post by:
Two observations about PEP-315: 1. It's clever, addresses a definite "wart", and is syntactically similar to try/except. But it's syntax seems like an acquired taste to me. 2. It is a very...
6
by: John Pass | last post by:
What is the difference between a While and Do While/Loop repetition structure. If they is no difference (as it seems) why do both exist?
3
by: Patrick Sullivan | last post by:
In this for loop, IE skips over the animation function until the end of the loop and only aninmates the last phrase. Firefox does it right. Loop is right below, entire script is below that. This...
34
by: Frederick Gotham | last post by:
Is the domestic usage of the C "for" loop inefficient when it comes to simple incrementation? Here's a very simple program that prints out the bit-numbers in a byte. #include <stdio.h> #include...
2
by: recordlovelife | last post by:
So I am trying to display a title, date, and content of a wordpress blog. Word press provides nice drop in functions to get the job done with simple names like "the_title", and the "the_content" But...
1
by: WiscCard | last post by:
I have an Access report that I need to print the 1st page on letterhead and the 2nd page on blank paper, then move on to the next record and do the same. I used the VBA code at the below link...
15
by: Steve | last post by:
I am having problems getting values out of an array. The array is set as a global array and values are pushed into it as they are read from a JSON file using a "for loop". When the "for loop" is...
9
by: Alexnb | last post by:
Okay, so lets say you have a list: funList = and you do: for x in funList: print x this will print 1-5
6
by: Alexnb | last post by:
Uhm, "string" and "non-string" are just that, words within the string. Here shall I dumb it down for you? string = "yes text1 yes text2 yes text3 no text4 yes text5+more Text yes text6 no...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.