I've seen interesting studies where people had their gallbladder ultrasounded, to prove no gallstones, then given different diets to follow for 6 months. Or told to keep eating as they normally did.
The diets had the same number of calories. The people on the high fat, low carb diet were fine, no increase in gallbladder disease, compared with the control group.
The people given current "official" dietary advice to follow (very low fat, very high carb/grain, almost all developed gallstones, although only a few had, within that short timeframe, developed painful attacks, the others had few or no symptoms!!!!
Remember, that was people with no gallstones, it only took a few months of low fat/high carb eating to grow them!
A person who already had stones before drastically cutting back on fat could get ill very very quickly.
This may sound odd, or counterintuitive, but the gallbladder actually NEEDS fat to empty, and low fat, high carb (especially wheat/gluten grains) affect both how often and how fast the gallbladder empties (studies have shown wheat/gluten slow the emptying of the gallbladder). These two things together lead to to much bile sitting for too long, forming sludge and stones, and eventually, illness.
So it is not the weight loss as such, but successfully sticking to the advised diet that can trigger it.
I managed to keep hold of my gallbladder by going grain free and increasing my fat intake (while still losing weight!). I was really sick to start with, but refused hospital treatment (pain thankfully not quite at the "I'm going to die" level).
I did a lot of reading about how the gallbladder works, and how the experiences of the pp in this thread (gallbladder surgery NOT curing the problem), it's really quite common and people are rarely told this, surgeons are more likely to blame the patient for having the cheek to remain ill, and may even say its all in your head. The pain is not phantom, it's real. The gallbladder is only one small part of the bile salts production system, the storage organ. Cutting it out doesn't stop the problems that might be causing the stones in the first place, there can be issues in the liver and ducts too.
I decided to give it a year, to try and cure the problem unconventionally by going grain free and slowly increasing my fat intake (needs to be done slowly to minimise serious attacks while the gallbladder and the rest of the system heal and become less inflamed. I had 6 months of gradually reducing attacks, then nothing. That was a couple of years ago. I consider my self very, very fortunate.
I followed the suggested protocol of a Swedish doctor (google dietdoctor.com lchf). Interestingly, this may also help people who have no gallbladder but still have gallstone attacks!