<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Dear Dave<div><br></div><div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>So, it looks like I'm just executing pro Fit scripts from Applescript with this, correct? </div></div></blockquote></div><div><br></div><div>Correct.</div><div><br></div><div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div> I suppose I could do the same with Python- modifying all of this stuff with a Python script?</div></div></blockquote><br></div><div>Correct.</div><div><br></div><div>Best regards</div><div><br></div><div>Kurt</div><div><br><div><div>On 9 Dec 2010, at 4:34, Dave wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi Kurt,<div><span class="Apple-tab-span" style="white-space:pre"> </span>Yes, those work. I'll play around and see if I understand the syntax enough to modify them to my satisfaction and get back to you if I can't. So, it looks like I'm just executing pro Fit scripts from Applescript with this, correct? I suppose I could do the same with Python- modifying all of this stuff with a Python script? Maybe this is a good time for me to learn Python, I'm in a shop now where that's the language of choice.</div><div><br></div><div>Thanks,</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Dave</div><div><br><div><div>On Dec 7, 2010, at 8:11 PM, pro Fit Support wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Dear Dave<div><br></div><div>This is a good question. In fact, it points to an error we have to fix. For the moment, as a work-around, use the "do script" and "evaluate" commands to get/set the axis range:</div><div><br></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b>tell</b> <span style="color: #1e39f6"><i>application</i></span> "pro Fit"</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; color: rgb(94, 97, 97); "><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">       </span></span>-- the following sets the start coordinate of the x-axis of the first curve of the current graph</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; "><span class="Apple-tab-span" style="white-space:pre">  </span><b>set</b> <span style="color: #4a8f28">xFirst</span> <b>to</b> -2.1243234</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; "><span class="Apple-tab-span" style="white-space:pre">       </span><span style="color: #1e39f6"><b>do script</b></span> "SetAxisProperties(axis GetPlotProperty(1, xAxis), first" & <span style="color: #4a8f28">xFirst</span> & ")"</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; color: rgb(94, 97, 97); "><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">     </span></span>-- the following gets the start coordinate</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; "><span class="Apple-tab-span" style="white-space:pre">        </span><b>set</b> <span style="color: #4a8f28">xFirst</span> <b>to</b> <span style="color: #1e39f6"><b>evaluate</b></span> "GetAxisProperty(GetPlotProperty(1, xAxis), first)"</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b>end</b> <b>tell</b></div></div><div><br></div><div>Best regards</div><div><br></div><div>Kurt Sutter</div><div>QuantumSoft</div><div><br></div><div><br><div><div>On 7 Dec 2010, at 5:25, Dave wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi Kurt,<div><span class="Apple-tab-span" style="white-space:pre">     </span>That's progress, but I'm still running into trouble. I can't seem to access any of the properties of a curve. One thing I'm wondering, are "first" and "last" reserved keywords in Applescript?</div><div><br></div><div>See below. Thanks!</div><div><br></div><div>Dave</div><div><br></div><div><br></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b>tell</b> <span style="color: #033efc"><i>application</i></span> "pro Fit 6.2.1"</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; color: rgb(95, 97, 97); "><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">     </span></span>-- these compile but don't execute</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; "><span class="Apple-tab-span" style="white-space:pre">        </span><b>get</b> <span style="color: #7f38d9">line dash</span> <b>of</b> <span style="color: #7f38d9">xAxis</span> <b>of</b> <span style="color: #033efc"><i>curves</i></span> 1 <b>of</b> <span style="color: #033efc"><i>shape</i></span> "1" <b>of</b> <span style="color: #033efc"><i>window</i></span> 1</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; "><span class="Apple-tab-span" style="white-space:pre">        </span><b>get</b> <span style="color: #7f38d9">name</span> <b>of</b> <span style="color: #7f38d9">xAxis</span> <b>of</b> <span style="color: #033efc"><i>curves</i></span> 1 <b>of</b> <span style="color: #033efc"><i>shape</i></span> "1" <b>of</b> <span style="color: #033efc"><i>window</i></span> 1</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; "><span class="Apple-tab-span" style="white-space:pre">     </span><b>set</b> <span style="color: #538e13">ax</span> <b>to</b> <span style="color: #7f38d9">xAxis</span> <b>of</b> <span style="color: #033efc"><i>curves</i></span> 1 <b>of</b> <span style="color: #033efc"><i>shape</i></span> "1" <b>of</b> <span style="color: #033efc"><i>window</i></span> 1</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; color: rgb(95, 97, 97); "><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">  </span></span>-- these don't compile</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 78.5px; text-indent: -78.6px; font: normal normal normal 12px/normal Verdana; color: rgb(95, 97, 97); "><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">       </span></span>get first of xAxis of curves 1 of shape "1" of window 1<span class="Apple-tab-span" style="white-space:pre">      </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 78.5px; text-indent: -78.6px; font: normal normal normal 12px/normal Verdana; color: rgb(95, 97, 97); "><span style="color: #000000"><span class="Apple-tab-span" style="white-space:pre">  </span></span>set first of ax to -10</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b>end</b> <b>tell</b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b><br></b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b>Error:</b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b><br></b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; "><b>error</b> "pro Fit 6.2.1 got an error: Cannot handle this object class. [System error -1723]" <span style="color: #033efc">number</span> -1723 <span style="color: #033efc">from</span> <span style="color: #7f38d9">line dash</span> <b>of</b> <span style="color: #7f38d9">xAxis</span> <b>of</b> <span style="color: #033efc"><i>curves</i></span> 1 <b>of</b> <span style="color: #033efc"><i>shape</i></span> "1" <b>of</b> <span style="color: #033efc"><i>window</i></span> 1</div></b></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 41.6px; text-indent: -41.6px; font: normal normal normal 12px/normal Verdana; "><b><br></b></div><div><div><div>On Dec 6, 2010, at 8:41 PM, Kurt Sutter wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Dave <div><br></div><div>Try</div><div><br></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; "><b>get</b> <span style="color: #7f38d9">xAxis</span> <b>of</b> <span style="color: #033efc"><i>curves</i></span> 1 <b>of</b> <span style="color: #033efc"><i>shape</i></span> "1"</div></div><div><div><div><br></div><div>Regards</div><div><br></div><div>Kurt Sutter</div><div>QuantumSoft</div><div><br></div><div>On 6. Dec 2010, at 17:12, Dave wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi all,<div><br></div><div>I'm trying to write an applescript that will change the Y1 and Y2 range of a graph.</div><div><br></div><div>I see that a graph is represented by the "shape" class, and I figure if I can get the first curve of that, I can get the axis to which it is associated. An "axis" class has properties "first" and "last" which denote the start and end coordinate of that axis, respectively.</div><div><br></div><div>However, my plan is hitting a snag. I can't seem to get the first curve of a shape:</div><div><br></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 83.2px; text-indent: -83.2px; font: normal normal normal 12px/normal Verdana; "><span class="Apple-tab-span" style="white-space:pre">      </span><b>set</b> <span style="color: #359700">curveBall</span> <b>to</b> <span style="color: #3a00ff"><i>curves</i></span> 1 <b>of</b> <span style="color: #3a00ff"><i>shape</i></span> "1"</div></div><div><br></div><div><br></div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; "><b>error</b> "pro Fit 6.2.1 got an error: Apple event was not handled. [System error -1708]" <span style="color: #3a00ff">number</span> -1728 <span style="color: #3a00ff">from</span> <span style="color: #3a00ff"><i>curves</i></span> 1 <b>of</b> <span style="color: #3a00ff"><i>shape</i></span> "1"</div></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; ">I can't even find what error -1728 means. Am I accessing the "curves" property correctly? Is this a reasonable way to get to the axes to change their range? </div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; ">Any and all help, much appreciated.</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; "><br></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; ">Dave</div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal Verdana; "><br></div></div>_______________________________________________<br>proFit-list mailing list<br><a href="mailto:proFit-list@quantum-soft.com">proFit-list@quantum-soft.com</a><br><a href="http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com">http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com</a><br></blockquote></div><br></div></div>_______________________________________________<br>proFit-list mailing list<br><a href="mailto:proFit-list@quantum-soft.com">proFit-list@quantum-soft.com</a><br><a href="http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com">http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com</a><br></blockquote></div><br></div></div></div>_______________________________________________<br>proFit-list mailing list<br><a href="mailto:proFit-list@quantum-soft.com">proFit-list@quantum-soft.com</a><br><a href="http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com">http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com</a><br></blockquote></div><br></div></div>_______________________________________________<br>proFit-list mailing list<br><a href="mailto:proFit-list@quantum-soft.com">proFit-list@quantum-soft.com</a><br><a href="http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com">http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com</a><br></blockquote></div><br></div></div>_______________________________________________<br>proFit-list mailing list<br><a href="mailto:proFit-list@quantum-soft.com">proFit-list@quantum-soft.com</a><br>http://quantum-soft.com/mailman/listinfo/profit-list_quantum-soft.com<br></blockquote></div><br></div></body></html>