Mix 1 cup of sugar, 1/2 cup of water and 1 Tablespoon of Borax. Place the solution in an old plastic container and poke holes in the lid so the ants can get in.
If you want to trap ants to collect them, I am not sure, but if you have an ant invasion: here is what you can do to easily be rid of ants safely and inexpensively:
Hi Walter: This is what I used for my ant problem, it may work for you, too.
Make a mix of 1/2 baking soda and 1/2 powdered sugar. Mix well and put around the spots they are in your garden, or inside your home, it's harmless to people and pets. For outside use, you can put it in a bottle, like a pill bottle or something like that. Cut a hole on the edge of the cap, and lay the bottle on it's side so the ants can come in and get the mix. This way, it stays dry if it should rain. They will take it back to the nest and it should kill them. I'd keep it out there all season if you can. The mix makes a gas and the ants can't pass gas, so it kills them. Anything else that eats it will just taste the baking soda and say "Yuck" and walk off. It won't hurt anything that can pass gas, so it's completely safe. It helps to know what type of ant you are trying to get rid of, too. Try this site, scrolling down to see the different types of ants and how to deal with them. https://www.thespruce.com/ant-control-4127879 Good luck.