Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Change order of existing items 2

Status
Not open for further replies.

ptuck

MIS
Aug 8, 2003
130
0
0
US
Okay GURU's I need your help again.

I have a form with a subform that holds steps to take to complete a task. At times we need to add a step in the middle of an existing task. What I would like to do is be able to click a button (add new step) that would allow me to add the step with the correct step number and then reorder the existing task. For example, I have "x" task that has 5 steps in it. We realize after trial and error that we should have one more step between steps 3 and 4. We would click the add new step button enter the step to take and then click save. This would take the new step entered (which is now step 4) and make step 4 step 5 and step 5 step 6. Is this possible?? I was thinking something along the lines of when the user clicks the add new step button it could dump the steps to a temp table and then do the massaging of the order. Please let me know what the GURU's think.

Thanks for the help,
Paul
 
KenReay, Your example worked perfect and I have given you a star...Thanks for all your help.

TheAceMan1, Your code is working great as well. I am goint to add some error handling to it and all shoule be perfect. I am still afraid the autokeys is not working. I am not sure how to test the serialize short cut. When I press Atl + s my machine just beeps. I am now about to read/sipher your code. I will let you know if I have more problems. Thanks again for all your help..

THANKS!!!! :)
 
ptuck said:
[blue]I am not sure how to test the serialize short cut.[/blue]
If for any reason StepID gets outof sequence (user inputs valid but but non-duplicate wrong valuse), you can re-serialize. To test, change a few StepID's to non-duplicate valid values.

Sames as your requirement of deleting a record. You need to re-serialize StepID.

Calvin.gif
See Ya! . . . . . .
 
It does work...I had commented out this part of the code becuase I did not have the function before and it was causing an error. However, it pops up a write conflict message (options are: "save record" "copy to clipboard" or "drop changes"). This is not a problem because it will allow the user to decide what they want to do, but if you do not select "save record" it produces an error on the requery of the form. Just thought I would share this, but everything appears to be working great.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top