Turning many curves from 2D to 3D - needing to do it one by one

I have about 140 curves that I want to turn from 2D to 3D… I tried selecting them all and changing them from 2D to 3D, but it in fact it only changes one. So basically I’m forced to do it one by one. How can I mass convert many curves from 2D to 3D?

save you file with new name !

try this script

import bpy
qtyCURVE = 0
for ob in bpy.data.objects:
 if ob.type == "CURVE":
  bpy.data.objects[ob.name].select = True
  curveob = bpy.context.active_object
  bpy.context.scene.objects.active = ob
  curveob.data.dimensions = '3D'
print ()
print ('Qty Curve =', qtyCURVE)

happy bl