Where do you want to return the data frame to? Still in cmd or back to the OS or to a file or something else? This is starting to sound like a language rather than a command shell. Richard ----- Original Message ----- From: "Al Puzzuoli" <alpuzz@xxxxxxxxx> To: "Program L" <program-l@xxxxxxxxxxxxx> Sent: Thursday, October 25, 2012 7:14 PM Subject: [program-l] Python, any way to return values when using the cmd module without using Globals? First of all, many thanks to everyone who is helping me along my path by ansering countless questions on this list. I am resolving issues, learning a bit more every day. Of course, the more I learn, the more I realize I don't know. My latest issue yet again has to do with the cmd module. The problem is that I was hoping to use it to implement for example, a method called do_new (). Do_new would prompt for a ticker symbol, read the data into a Pandas DataFrame, and then return the DataFrame. However, cmd's methods apparently don't return values other than success or failure codes. I can make this work if I declare my DataFrame as a global variable but of course, I assume there must be a better way? Thanks, Al ** To leave the list, click on the immediately-following link:- ** [mailto:program-l-request@xxxxxxxxxxxxx?subject=unsubscribe] ** If this link doesn't work then send a message to: ** program-l-request@xxxxxxxxxxxxx ** and in the Subject line type ** unsubscribe ** For other list commands such as vacation mode, click on the ** immediately-following link:- ** [mailto:program-l-request@xxxxxxxxxxxxx?subject=faq] ** or send a message, to ** program-l-request@xxxxxxxxxxxxx with the Subject:- faq ** To leave the list, click on the immediately-following link:- ** [mailto:program-l-request@xxxxxxxxxxxxx?subject=unsubscribe] ** If this link doesn't work then send a message to: ** program-l-request@xxxxxxxxxxxxx ** and in the Subject line type ** unsubscribe ** For other list commands such as vacation mode, click on the ** immediately-following link:- ** [mailto:program-l-request@xxxxxxxxxxxxx?subject=faq] ** or send a message, to ** program-l-request@xxxxxxxxxxxxx with the Subject:- faq