Subscribe Bookmark RSS Feed

Error: "Tried to access window, but not connected" What does it mean and how can I solve it?

jan_solo

Community Trekker

Joined:

Feb 21, 2014

I keep getting the same error in my script:

"Tried to access window, but not connected"

What does it mean and how to solve / work around it.

I think it has something to do with

New Window("MyWindow",

tt = V List Box()

);

For (i = 2, i <= N Col(InputTable), i++,

     Expr(

          tt << append(

               H List Box( <Create Chart> )

          )

     )

);

Can someone tell me what is wrong with the expression...  I get an emty window and an error message in the log file.

Thanx...

1 ACCEPTED SOLUTION

Accepted Solutions
Solution

I don't know about that error message. But to populate the empty window the expression need to be evaluated. Or just skip the expr() wrapper.

Example:

InputTable = Open( "$SAMPLE_DATA/Drug.jmp" );

New Window( "MyWindow", tt = V List Box() );

For( i = 2, i <= N Col( InputTable ), i++,

  tt << append(

  H List Box(

  Text Box( "Chart " || Char( i - 1 ) ),

  InputTable << oneway( Y( Column( i ) ), X( Column( 1 ) ) )

  )

  )

);

1 REPLY
Solution

I don't know about that error message. But to populate the empty window the expression need to be evaluated. Or just skip the expr() wrapper.

Example:

InputTable = Open( "$SAMPLE_DATA/Drug.jmp" );

New Window( "MyWindow", tt = V List Box() );

For( i = 2, i <= N Col( InputTable ), i++,

  tt << append(

  H List Box(

  Text Box( "Chart " || Char( i - 1 ) ),

  InputTable << oneway( Y( Column( i ) ), X( Column( 1 ) ) )

  )

  )

);