Operator doesn't work when invoked from Panel, but works when invoked using the spacebar
There are two issues with your code, and I presume your button doesn't actually call this code, but an older version of your operator:


bl_idname = "load.pointCloud" is an invalid name, only lower-case characters are allowed. Bad naming will make the operator registration fail.
The path to your .ply file contains backslashes, but you didn't escape them. You can use a raw string (r"C:\path\to\file.ext") to avoid lots of \\.




class LoadPointCloud_Button(bpy.types.Operator):
    bl_idname = "load.pointcloud"
    bl_label = "Load Point Cloud"
    bl_description = "Load the point cloud"
    bl_options = {'UNDO'}

    def execute(self, context):
        bpy.ops.import_mesh.ply(filepath=r"C:\sfmoutput\pmvs\models\option-0000.ply")
        return {'FINISHED'}

def register():
    bpy.utils.register_class(LoadPointCloud_Button)

def unregister():
    bpy.utils.unregister_class(LoadPointCloud_Button)

if __name__ == "__main__":
    register()