As far as the original question, yes, it works. Though you seem to have figured it out :-p. You’re doing a standard precipitation experiment, exchanging the ions to create two new salts (one soluble and one insoluble) from the two starting salts.
As far as color goes, you may be able to do colored smoke that way (though i would expect most dyes are going to combust in the heat given off by the saltpeter), but you can also do colored flames/sparks/etc from mixing in other salts, look here (though, fair warning, you should not do Magnesium Sulfate. It not only makes white light, but quite a lot of UV, and thus can blind you. Bad stuff)