No accessible overloaded

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

We got back "No accessible overloaded. "Streamwriter.writeline is most
specific for these arguments:

Overrides Public Sub Writeline(ByVal buffer as Char() ).
Overrides Public Sub Writeline(ByVal value as char)

This occurred when we were doing a routine that had to write to a number of
files. We've not seen this before and there have been no recent code
changes. Ideas? Thank you.
 
Jeffrey Howard said:
We got back "No accessible overloaded. "Streamwriter.writeline is most
specific for these arguments:

Overrides Public Sub Writeline(ByVal buffer as Char() ).
Overrides Public Sub Writeline(ByVal value as char)

This occurred when we were doing a routine that had to write to a number of
files. We've not seen this before and there have been no recent code
changes. Ideas? Thank you.

Could you post a short but complete program which demonstrates the
problem?

See http://www.pobox.com/~skeet/csharp/complete.html for details of
what I mean by that.
 
Dim objStreamWriter As StreamWriter
objStreamWriter = File.AppendText(strOutName)
objStreamWriter.WriteLine(strChargeFlag)
objStreamWriter.WriteLine(strUseShortCode)
objStreamWriter.WriteLine(strSenderMobileTx)
objStreamWriter.WriteLine(StrMessage)
objStreamWriter.Close()
 
Jeffrey Howard said:
The actual program is hundreds of lines of code. The data for the variables
are supplied elsewhere. Has this problem been reported before? We did a KB
search prior to our posting and did not find this problem. Short of
providing a program hundreds of lines long, which will not be possible
because of non disclosure requirements, are their specific areas of
streamwriter use you'd suggest we look at.

You don't have to provide the whole *real* program - just a small
program which demonstrates the same issue. I suggest you either start
from an empty project and add bits until it breaks in the same way, or
take a copy of your real project and remove parts of that until it's
short and complete but still breaks.

There should be no need to have any business logic in there - only the
bit that breaks.
 
Back
Top