Step 1:
Create a comp 50x50pixels. Use the paint bucket tool and fill it black. Press Ctrl A to select all and Ctrl C to copy
Step 2:
Now go to the comp you like to add the effect. Press Ctrl V to paste the square into the comp. Move it to the upper left corner so it snaps in place.
Step 3:
Duplicate the square and snap it next to the first square. Then on your keyboard press the arrow key right 10times to make some space between the squares. Merge the layers together and duplicate again. This time snap to the bottom of the square and press the down arrow 10times to make some space.
Step 4: Repeat step 3 until you filled the comp.
Step 5: To adjust the size of the dots click (edit-Transform-Scale and hold down Shift to keep the proportions correct.
Step 6: Fool around of layer styles for fun!
Step 7: Enjoy