Will glucose or dextrose 50% help treat leg cramps for patients during dialysis? Why or why not?

Depends. If it is a glucose issue - yes. If it is an electrolyte issue or a vascular issue - probably not. Make sure to tell your doctor you are having these cramps.
50% D5W for cramps. Patients who cramp on dialysis may do due to changes in serum osmolarity (o). Sodium, glucose and urea nitrogen (u) are the major determinants of o. As u is removed from the patient's blood, the o falls. You can elevate o quickly by giving either IV d50w, (dextrose) or with IV hypertonic saline, both of which will increase o, relieving cramps in hd patients having them on dialysis.
Doubt. But, possible. Usually cramps are due to electrolyte or fluid changes. So, saline (sodium electrolyte) is effective. In cases of fluid alteration i.e.Dehydration, dextrose 50 will remove water out of muscles by osmosis and make it more dehydrated. However, in cases of the opposite (over hydration) it may work. But the latter is usually not the common mechanism.During dialysis. Cramps occur w fluid & salt removal.