Count number of email messages in a mailbox

this I know is going to be a very dumb question but I cannot figure out the correct syntax to count the number of messages in a mailbox. My efforts are shown in the following script none of which have worked.


tell application "Mail"
	
	
	set m_boxes to the name of every mailbox
	
	set this_box to choose from list ((m_boxes))
	
	
	set y to ((count of (messages of this_box)) as string)
	set y to (count of every message in this_box)
	set y to count every message of this_box
	set y to count (messages of this_box)
	set y to count messages in this_box
	display dialog y
	
	
end tell

I would appreciate any suggestions.

Thanks

Peter

Jacques

Thanks so much that works fine as I said I knew it was a dumb question, sometimes the syntax just beats me.

thank you

Model: G%,Power Book , Mini
Browser: Safari 417.8
Operating System: Mac OS X (10.4)