In the below routine, if i pass a value it stores it in common and if i give argument values as 'Get', it returns the old value stored in COMMON.
The below routine works for a process i.e., in a transformer when i keep switching between arguments values.
But i wanted to store the value in one transformer and retrieve the value in another transformer.
Read in the manual that i need to use something like
$INCLUDE InitializeToCommon.H in my routine.
But, if i use the above line directly in my code, it would give error: Unable to open DSU_BP/InitializeToCommon.H
Code: Select all
InitializeToCommon(Arg1)
-----------------------------------------------
Common /InitializeToCommon/ Initialize, LastValue
RoutineName='InitializeToCommon'
Ans = ''
If Arg1='Get' Then
Ans=LastValue
End Else
If Initialize Then
Ans=''
LastValue=Arg1
End Else
Initialize = 1
LastValue = Arg1
End
End
Can anyone write me a steps how to do it with some modification to above routine?