i don't remember the scripts coming out in order, I'm testing it now...the wierd thing is, on a decent size database, with 2000+ objects, it's still running the Script wizard for over an hour....on TWO different servers, since i thought maybe it was just me.
I did notice it is going thru the objects in object type, then alphabetical order, but it might be arranging the data in dependancy order...not sure yet.
the easiest way to get all your objects in order is to run this command:
EXEC sp_msdependencies @intrans = 1
I've used this to manually script all my objects via TSQL...tables, functions/procs/views.
--help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!