INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Jobs

ERROR IN GETTING QUEUE

ERROR IN GETTING QUEUE

(OP)
I keep getting an error because of the GET().
First my code was:

FREE(qTest2)
LOOP i# = 1 TO RECORDS(Queue:Browse:1)
  GET(Queue:Browse:1, i#)
    IF ERRORCODE() THEN
      MESSAGE(ERROR(),ERRORCODE())
      BREAK
    END
  IF ... THEN !Filter -Condition
    qTest2.Data = Queue:Browse:1.Data
    ADD(qTest2)
  END
END

But then it would just skip the whole loop like it wasn't even there, so i wrote it like this:

FREE(qTest2)
i# = 1
LOOP
  GET(Queue:Browse:1, i#)
    IF ERRORCODE() THEN
      MESSAGE(ERROR(),ERRORCODE())
      BREAK
    END
  IF ... THEN !Filter -Condition
    qTest2.Data = Queue:Browse:1.Data
    ADD(qTest2)
  END
i#=i#+1
END

And the message is:
Entry Not Found.
Errorcode is 30

Does anybody know what could cause this error?

RE: ERROR IN GETTING QUEUE

Hi!

If there are 4 rows in the Browse:queue:1 and you try to access the fifth row, it will return an error of Entry Not found. Change your code to ::

CODE

    IF ERRORCODE() = 30
       BREAK
    ELSIF ERRORCODE()
       MESSAGE(ERROR(),ERRORCODE())
       BREAK
    END

Your first loop code seems fine and the I think the problem is with your filter condition.

Regards


Regards
 

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Resources

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close