Link to home
Start Free TrialLog in
Avatar of NJordan72
NJordan72

asked on

Forms & Arrays

Hello-

Here is what I am trying to do, and I'm not sure of the best way to go about it.  I have a form that is going to store information about a UPS shipment.  This shipment can contain  many boxes.  (If you are familiar with UPS World Ship, it will make this easier to explain.)  I would like to display the info on the boxes one at a time, and allow the user to add/delete/scroll through the boxes and look at the info.

What is the best way to accomplish this?  I'm thinking for every piece of information I have on the boxes, I could create an array.  When a user scrolls, i could update all of the forms with the new info.  Same thing for adding and deleting.

Is this the best way to go at this?  Thanks!
Avatar of wolfpackinc
wolfpackinc

What Compiler are you using?
What you need is a DataBase.
Unless this is homework?
Avatar of DanRollins
The best way would be to create a structure that contains each piece of information needed to fill the form.  Then make an array of those structures.  

When the [Next] button is clicked, point to the next higher structure in the array, and populate the form with that data.  Similarly, on [Prev], point the the next lower-numbered array element.  Add error checking to not go beyond either end of the arrya.

Do you need help in creating and using an array of structures?

-- Dan
Avatar of NJordan72

ASKER

Thanks Dan...

When you say structures, are you talking about struct(s) or are you talking about the form elements that will be changing?

If you could give me a little code snippit it would push me in the right direction!  
ASKER CERTIFIED SOLUTION
Avatar of DanRollins
DanRollins
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
hi NJordan72,
Do you have any additional questions?  Do any comments need clarification?

-- Dan
NJordan72:

You have many open questions:

https://www.experts-exchange.com/jsp/qShow.jsp?ta=asp&qid=20175227
https://www.experts-exchange.com/jsp/qShow.jsp?ta=visualbasic&qid=20130164
https://www.experts-exchange.com/jsp/qShow.jsp?ta=visualbasic&qid=20165375
https://www.experts-exchange.com/jsp/qShow.jsp?ta=visualbasic&qid=20184291
https://www.experts-exchange.com/jsp/qShow.jsp?ta=cplusprog&qid=20256443
https://www.experts-exchange.com/jsp/qShow.jsp?ta=cplusprog&qid=20260378

To assist you in your cleanup, I'm providing the following guidelines:

1.  Stay active in your questions and provide feedback whenever possible. Likewise, when feedback has not been provided by the experts, commenting again makes them receive an email notification, and they may provide you with further information. Experts have no other method of searching for questions in which they have commented, except manually.

2.  Award points by hitting the Accept Comment As Answer button located above and to the left of that expert's comment.

3.  When grading, be sure to read:
https://www.experts-exchange.com/jsp/cmtyQuestAnswer.jsp#3
to ensure that you understand the grading system here at EE. If you grade less than an A, you must explain why.

4.  Questions that were not helpful to you should be PAQ'd (stored in the database for their valuable content?even if not valuable to you) or deleted. To PAQ or delete a question, you must first post your intent in that question to make the experts aware. Then, if no experts object after three full days, you can post a zero-point question at community support to request deletion or PAQ. Please include the link(s) to the question(s).
CS:  https://www.experts-exchange.com/jsp/qList.jsp?ta=commspt
At that point, a moderator can refund your points and PAQ or delete the question for you. The delete button does not work.

5.  If you fail to respond to this cleanup request, I must report you to the Community Support Administrator for further action.

Our intent is to get the questions cleaned up, and not to embarrass or shame anyone. If you have any questions or need further assistance at all, feel free to ask me in this question or post a zero-point question at CS. We are very happy to help you in this task!


thanks!
amp
community support moderator