Origin Version (Select Help-->About Origin): 7.5G SR6
Operating System: XP
Hello,
I experience a couple of problems when trying to alter the Properties of Graph-Axes. The code looks like this (mostly thanks to Mike
):
GraphPage graphFourier("FFTPlot");
if (!graphFourier)
{
graphFourier.Create("FFT"); // Graph erzeugen
graphFourier.Rename("FFTPlot");
LT_execute("lab -xb (Frequenz [THz]);");
LT_execute("lab -yl (Amplitude);");
}
GraphLayer graphSchicht2 = graphFourier.Layers(); // Schicht im Graph erzeugen
Curve kurveFourier(tabelleFourier,0,3); // Kurve definieren
string kurveName2 = kurveFourier.GetName(); // name of curve
DataPlot kurvePlot2(graphSchicht2.DataPlots(kurveName2));
if( !kurvePlot2 ) // if data plot does not exist
graphSchicht2.AddPlot(kurveFourier, IDM_PLOT_LINE);
graphSchicht2.Rescale(); // Skalieren
graphSchicht2.X.From = 0;
graphSchicht2.X.To = 5;
graphSchicht2.Y.Type = 1;
graphSchicht2.Y.From = 0;
graphSchicht2.Y.Inc = 1;
graphSchicht2.Y.MajorTicks = 8;
graphSchicht2.X2.ShowAxes = 1;
graphSchicht2.Y2.ShowAxes = 1;
- On the last 3 lines, I get "Variable is not defined"-Errors. The "to"-, "from"- and "inc"-properties above work just fine, besides the "majorticks" property some others like "ticks", "minorticks", "opposite" and so on give me the same error. Letter capitalization is not the reason, I basically tried every possibility. (Btw, the Properties that work only do so when the first letter is capitalized, in the help-file they are all lower-case, just for the record).
Now I dont have any clue why some properties work and others just dont.
-The Second problem is, that on the last 2 lines i get an additional error in the Script-Window which says "<*><*><*><*><*><*> ID translation format error."
Obviously the right X- and the upper Y-Axis are not useable and again I have no clue why this is so. I tried
Scale xAchseRechts(graphSchicht2.X2)
because I thought I had to define them first, but this didnt work either.
I dont know if maybe another problem has to do with this:
Since this morning, everytime I run the Programm i get this Message in the Script-Window:
"@@@@@PLEASE REPORT THIS ERROR Class member not linked to dll"
The Programm seems to run fine, and frankly I dont know what or where to report to.
Thanks in advance for your help and have a nice weekend everyone
Tobi
Edited by - klunz on 09/21/2007 04:29:29 AM