openerp echo the return result of a function
If your purpose is to debug, the simplest solution is to add print statements in your code and then run the server in a console.
In openerp, im working on a dummy function that (for example) returns the sum of a certain field on selected records.
for instance, u select 3 invoices and it returns the sum of the quantity in the invoice lines. i think the function to perform the sum is correct, and even if it wasnt, i just need help in displaying the result of the function when called in a popup box. for that, i've added an action similar to "Confirm Invoices" found in the invoice object.  
to make myself clearer, when the confirm invoice is pressed, its function is called and the popup previously opened is of course closed because of this line found in the function: return {'type': 'ir.actions.act_window_close'}
how can i tell it in my function instead (of closing) to display the result stored after executing the function?