Trouble with lineTo

I’m new so please bear w/ me…
On the main stage i have a movie clip that contains a movie clip that contains a bitmap (_root.movieclip1.movieclip2.bitmap). The actions for the instance of movieclip2 cause the bitmap to follow a sine wave path across the stage.
I’d like to draw a line behind the bitmap, so I created another movieclip on the main stage that has these actions:

onClipEvent (load) {
moveTo (##x and y positions from other movieclip##);
}

onClipEvent (enterFrame) {
lineStyle (5, 0xff00ff, 100);
lineTo (##x and y positions from other movieclip##);
}

the timeline only has one frame (can this be done with only one frame??)
anyway, I’m lost and would appreciate some help, thanks in advance.

So what does it do?

It does nothing, there are no lines, just the bitmaps moving across the stage.

Isn’t that because if you use the lineTo command it acts alot like the moveTo command.
Difference: moveto only moves your pen to the point specified. Lineto moves the pen to that specific point, but also draws a line from the starting point.

In other words if you use the lineto command in the way you are trying to do, it is basically trying to draw a line from your coordinates to the same coordinates, thus not drawing any visible line.

so how could i get the line drawn? i’m stuck

Are you sure it’s not a scope issue? Can you trace the coordinates of that clip you’re tracking?

hey nah what ur missing is moveTo
so
moveTo(object._x,object._y)
lineTo(object1._x,object._y)
thats what ur trying to do right i made an example kinda thing for fun i call it the funlines
http://home.1asphost.com/lordsamot/funlines.swf

Nope. lineTo also moves the pen, so I think the problem comes from something else.