comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Error in Object
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Error in Object [message #46078] Thu, 03 November 2005 01:34
IDLmastertobe is currently offline  IDLmastertobe
Messages: 54
Registered: June 2004
Member
Hi, i am trying to set property of a IDLgrView, but i received an error.
The code is as follows:

pro demo_draw, state, oWindow, oView, debug=debug
;
;Procedure DEMO_DRAW: call oWindow->Draw, oView
;wrapping the call in !except=0 if not DEBUG.
;
;On some platforms, when IDLgrWindow::Draw is invoked, math errors
;(e.g. "% Program caused arithmetic error: Floating illegal
;operand") are printed. DEMO_DRAW exists to supress the printing of
;these errors.
;
;Flush and print any accumulated math errors
;
void = check_math(/print)
;
;Silently accumulate any subsequent math errors, unless we are debugging.
;
orig_except = !except
!except = ([0, 2])[keyword_set(debug)]
;
;Draw.
;

oView->SetProperty, COLOR=[100,100,100]

oWindow->Draw, oView

;
;Silently (unless we are debugging) flush any accumulated math errors.
;
void = check_math(PRINT=keyword_set(debug))
;
;Restore original math error behavior.
;
!except = orig_except
end

oView property is something i want to change. and I received an error:
"Object reference type required in this context: OVIEW.". If instead of
having [100,100,100] as the color, i use [state.BR, state.BB, state.BG],
which are data saved in state structure, i receive another error:
"Object instance data is not visible outside class methods: STATE". Does
anyone know why? Thank you.
[Message index]
 
Read Message
Previous Topic: Command line history in IDLWAVE shell
Next Topic: Extracting arrays into txt files

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 10:33:59 PDT 2025

Total time taken to generate the page: 0.64188 seconds