Try<br><br>bpy.context.scene.frame_set()<br><br>Operators rely on context so it can get hard to satisfy them (you could also try making a timeline window visible). You can override context by paying an optional dict to the operator but I've found this tricky to get right in practice.<br>Oh, and welcome to this blender thing,<br>Bassam<br><br> "Cook, Rich" <cook47@llnl.gov> wrote:<br><br><html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">
Hi, I'm new to this here blender thingie.  I was trying some code out to import a few meshes from a science run, and am getting an error I cannot get past.  I was going to import the timesteps as separate meshes, then set keyframes on visibility for each mesh
 at different timesteps in order to "animate" them.  Per <a href="http://blenderscripting.blogspot.de/2011/07/scripted-keyframing-of-hide-hide-render.html">http://blenderscripting.blogspot.de/2011/07/scripted-keyframing-of-hide-hide-render.html</a>
<div><br>
</div>
<div>I am getting the following error: </div>
<div><br>
</div>
<div>
<div>>>> bpy.ops.anim.change_frame(frame = 5)</div>
<div>Traceback (most recent call last):</div>
<div>  File "<blender_console>", line 1, in <module></div>
<div>  File "/Volumes/MacProHD/cook47-stuff/Programs/graphics/Blender/blender.app/Contents/MacOS/2.68/scripts/modules/bpy/ops.py", line 188, in __call__</div>
<div>    ret = op_call(self.idname_py(), None, kw)</div>
<div>RuntimeError: Operator bpy.ops.anim.change_frame.poll() Expected an timeline/animation area to be active</div>
<div><br>
</div>
<div>I do have a timeline visible in the GUI.  I'm not sure what blender is trying to tell me.  </div>
<div><br>
</div>
<div>I'm probably going to change approaches and just load one mesh at a time, set up the scene, render, and move to the next, etc.  However, my technical curiosity has the best of me here.  I'd like to understand why I cannot set a timestep here.</div>
<div><br>
</div>
<div>Thanks!  </div>
<div><br>
<div apple-content-edited="true"><span class="Apple-style-span" style="border-collapse: separate; font-size: 13px; border-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Monaco; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Monaco; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><span class="Apple-style-span" style="border-collapse: separate; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; color: rgb(0, 0, 0); font-family: Monaco; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; -webkit-text-decorations-in-effect: none; text-indent: 0px; -webkit-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><span class="Apple-style-span" style="border-collapse: separate; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; color: rgb(0, 0, 0); font-family: Monaco; font-size: 13px; font