** already has a conflicting use. (99)

rajesh4you

New Member
Hi friends,

Please throw some light on the below error if possible with an example.
"** already has a conflicting use. (99)"

For me the <file-name> value is coming blank.
 

taqvia

Member
Can you please let us know in bit detail about the issue. Is this coming during report generation where you are trying to write the output to same file in multiple threads ....

Please be more specific so that we can try to provide a solution


Arshad
 

sphipp

Member
Hi friends,

Please throw some light on the below error if possible with an example.
"** already has a conflicting use. (99)"

For me the <file-name> value is coming blank.


Code:
DEFINE VARIABLE cfilename AS CHARACTER  NO-UNDO.
DEFINE STREAM sout.
ASSIGN cfilename = CHR(160).
OUTPUT STREAM sout TO VALUE (cfilename).
OUTPUT STREAM sout TO VALUE (cfilename).
OUTPUT STREAM sout CLOSE.
OUTPUT STREAM sout CLOSE.

Error 99 happens when you have a file opened for output and you try and reopen it for output without closing it.

The filename being blank is probably due to the program defining a filename using non-visible characters. You can replicate the effect using the above code.

You fix it by finding where the file is opened (OUTPUT TO) then second time and ensure the file is closed (OUTPUT CLOSE) before it is reopend. I'd MESSAGE VIEW-AS ALERT-BOX the output filename to see what it is.
 

shireeshn

Member
You have already assined a stream to one file and trying to assign to other file(it may be same file) this is the reason.

when progress comes to 4th line that "output to stream" then stream is fixed to that output statement, but when the pointer comes to 5th line it has encountered output again with same stream so this error will be thrown.

In a simple way to say, already assined stream cannot be reassined to some other. U also know this but if u dont know (remove one of the 4th or 5th) line then it works fine.
 
Top