I once read about a mortar that starts as a powder I could put in between my flagstones, and then just wet it down and it would harden in place.
Do you know what this product is?
I have used Polymeric Sand in this way.
For pavers, you sweep it into the joints, wet it and it hardens in place.
This has worked well to prevent weed growth and washout from water, but it does not obstruct ants from tunneling. They seem just as capable of prying this glue/sand apart as regular sand.
No special mix is required. It is a technique called dry grouting.
To use this the surface MUST be dry and done during a sunny day.
You must realise though that this is rarely used because the outcome is not very pretty, using stains in the mix can cause stains on your flagstones too and is really only used straight after your flagstones are put down or there is enough ground moisture to help the mix set.
First of all, a caveat:
A basic dry mix is 4:1 sand to cement. That's by volume, not weight. I'd try to find a fine sand, and preferably sharp cornered.
You may be able to find a premix at your patio/garden center.
The problem here is that all cement compounds require a significant amount of water to cure, and your joints will need water from the bottom as well as the top. You might be better off using a wet mix and just taking the time to apply it carefully.