With Siemens I've always found the standard counters lacking. You can build your own counter similar to what has been described.
If you want your counter logic to look like a box to simplify things when you call it:
You can write the add instruction, compare instruction, reset instruction, etc in an FC using inputs & outputs declared within the FC. Then when you call this FC it will look like a counter box you'd get in Allen-Bradley.
If you need more help then holler back.