How to check if an order is selected - page 2

 
FAQ:
by the number in the loop.

The task is to write a separate function that does something with orders, can be called from different parts of the code, and needs to not reset the index of the currently selected order that was selected when the function was called. In this case, if the order has not been selected at the time the function is called, the function must not generate error 4105

 

1) go through all the orders, and write their tickets in an array.

2) Tickets don't go anywhere, if the order was there, it's there.

 
FAQ:

1) Your question is essentially meaningless.

Strangely enough, I think your answer is essentially meaningless.

 
Ant_TL:

Strangely enough, it seems to me that your answer is essentially meaningless.


If you have such questions, I highly recommend throwing out your code, or better yet, your approach to programming.
 
FAQ:

If you have such questions, I highly recommend throwing out your code, or better yet, your approach to programming.

Thank you for your informative, and most importantly sound, advice

 
Ant_TL:

Thanks for the informative advice


You're welcome, you can't possibly understand any other arguments.
 
FAQ:

You're welcome, you can't understand any other arguments.

Maybe you know how to find out if an order is currently selected or not without getting a 4105 error?

 
Ant_TL:

Maybe you do know how to find out if an order is currently selected or not without getting a 4105 error?

Why are you worried about an error? If there is an error, it means that the order is not selected. If there is no error, it means it has been selected. Error handling so to speak, absolutely standard approach. And your code is definitely not good.
 

the order is a selection and nothing else.

1 What prevents you from storing the ticket of a pre-selected order in a variable and then checking if it is correct?

the rest is what I said before:

FAQ:

1) go through all the orders, and write their tickets in an array.

2) Tickets are not going anywhere, if the order was, it is there.

 
Figar0:
And your code is definitely not good.

If you do say so, justify your point of view

The error is "scary" because there shouldn't be any errors