fitztho 0 Newbie Poster

I am looking to use a string to call a variable in assembly

I have the following:

msg_0      db   "Random phrase",10,0
msg_1      db   "Another Random Phrase",10
...(more messages)
msg_11    db  "Final Random Message",10,0 
msgIndex db  "msg_%d",0

then have the program push msgIndex and a random number to print one of the messages.

Is there a way that I can do this?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.