File Operators

bpy.ops.file.bookmark_add()

Add a bookmark for the selected/active directory

bpy.ops.file.bookmark_toggle()

Toggle bookmarks display

bpy.ops.file.cancel()

Cancel loading of selected file

bpy.ops.file.delete()

Delete selected file

bpy.ops.file.delete_bookmark(index=-1)

Delete selected bookmark

Parameters:index (int in [-1, 20000], (optional)) – Index
bpy.ops.file.directory()

Enter a directory name

bpy.ops.file.directory_new(directory="")

Create a new directory

Parameters:directory (string, (optional)) – Directory, Name of new directory
bpy.ops.file.execute(need_active=False)

Execute selected file

Parameters:need_active (boolean, (optional)) – Need Active, Only execute if there’s an active selected file in the file list
bpy.ops.file.filenum(increment=1)

Increment number in filename

Parameters:increment (int in [-100, 100], (optional)) – Increment
bpy.ops.file.find_missing_files(filepath="", filter_blender=False, filter_image=False, filter_movie=False, filter_python=False, filter_font=False, filter_sound=False, filter_text=False, filter_btx=False, filter_collada=False, filter_folder=False, filemode=9)

Undocumented (contribute)

Parameters:
  • filepath (string, (optional)) – File Path, Path to file
  • filter_blender (boolean, (optional)) – Filter .blend files
  • filter_image (boolean, (optional)) – Filter image files
  • filter_movie (boolean, (optional)) – Filter movie files
  • filter_python (boolean, (optional)) – Filter python files
  • filter_font (boolean, (optional)) – Filter font files
  • filter_sound (boolean, (optional)) – Filter sound files
  • filter_text (boolean, (optional)) – Filter text files
  • filter_btx (boolean, (optional)) – Filter btx files
  • filter_collada (boolean, (optional)) – Filter COLLADA files
  • filter_folder (boolean, (optional)) – Filter folders
  • filemode (int in [1, 9], (optional)) – File Browser Mode, The setting for the file browser mode to load a .blend file, a library or a special file
bpy.ops.file.hidedot()

Toggle hide hidden dot files

bpy.ops.file.highlight()

Highlight selected file(s)

bpy.ops.file.make_paths_absolute()

Undocumented (contribute)

bpy.ops.file.make_paths_relative()

Undocumented (contribute)

bpy.ops.file.next()

Move to next folder

bpy.ops.file.pack_all()

Undocumented (contribute)

bpy.ops.file.parent()

Move to parent directory

bpy.ops.file.previous()

Move to previous folder

bpy.ops.file.refresh()

Refresh the file list

bpy.ops.file.rename()

Rename file or file directory

bpy.ops.file.report_missing_files()

Undocumented (contribute)

bpy.ops.file.select(extend=False, fill=False)

Activate/select file

Parameters:
  • extend (boolean, (optional)) – Extend, Extend selection instead of deselecting everything first
  • fill (boolean, (optional)) – Fill, Select everything beginning with the last selection
bpy.ops.file.select_all_toggle()

Select/deselect all files

bpy.ops.file.select_bookmark(dir="")

Select a bookmarked directory

Parameters:dir (string, (optional)) – Dir
bpy.ops.file.select_border(gesture_mode=0, xmin=0, xmax=0, ymin=0, ymax=0, extend=True)

Activate/select the file(s) contained in the border

Parameters:
  • gesture_mode (int in [-inf, inf], (optional)) – Gesture Mode
  • xmin (int in [-inf, inf], (optional)) – X Min
  • xmax (int in [-inf, inf], (optional)) – X Max
  • ymin (int in [-inf, inf], (optional)) – Y Min
  • ymax (int in [-inf, inf], (optional)) – Y Max
  • extend (boolean, (optional)) – Extend, Extend selection instead of deselecting everything first
bpy.ops.file.smoothscroll()

Smooth scroll to make editable file visible

bpy.ops.file.unpack_all(method='USE_LOCAL')

Undocumented (contribute)

Parameters:method (enum in [‘USE_LOCAL’, ‘WRITE_LOCAL’, ‘USE_ORIGINAL’, ‘WRITE_ORIGINAL’, ‘KEEP’], (optional)) – Method, How to unpack

Previous topic

Export Scene Operators

Next topic

Fluid Operators