Sign up on the Revelation Software website to have access to the most current content, and to be able to ask questions and get answers from the Revelation community

At 26 FEB 2004 04:48:16PM Charlie Engler wrote:

Hello,

Just made the move to OI7 and ran across my first problem. I wrote a function to supply a default value to a field. On the Edit Line Properties window in the "Default" field, I placed the name of my custom function.

Each time the focus switches to the field, the function is processed correctly but then the form crashes and the debugger opens with the following error message: "Eng0010: OIWIN_GOTFOCUS, Line 2. Variable has not been assigned a value."

I've tried this function on different fields, different forms and different applications, including SYSPROG. I even wrote a very simple function to see if that might be the problem…same results.

I've made no changes to my system since installing OI7.

Any suggestions?

Thanks,

Charlie


At 27 FEB 2004 02:58AM The Sprezzatura Group wrote:

A default function must be a function, and have the return results returned as part of the return statement.

So, when testing this

Subroutine TestDefault( Void )
RetVal=OConv( Time(),'MTS')
@ANS=RetVal
Return

we received the same error. However,

FunctionTestDefault( Void )
RetVal=OConv( Time(),'MTS')
Return RetVal

happily placed the time into our test prompt.

The Sprezzatura Group

World Leaders in all things RevSoft


At 27 FEB 2004 08:14AM Charlie Engler wrote:

Thanks, it works great now. I've got to shift my thinking from the world of AREV RBasic to OI Basic+.

Charlie

View this thread on the forum...

  • third_party_content/community/commentary/forums_nonworks/3f1eaeb3af9d34e885256e460077c6b4.txt
  • Last modified: 2024/01/04 21:00
  • by 127.0.0.1