convert to VB

  • Thread starter Thread starter TJS
  • Start date Start date
T

TJS

I cannot seem to get this to convert to VB.
tried the converter at asp-alliance but it throws an error on line marked

I tried the kamapatel converter, which did not throw an error, but the
result did not compile

any experts available ?

===== code ====
.....
protected override AddInForm CreateAddInForm() {
String sDocumentName = base.Document.DocumentName;
String sDocumentPath = base.Document.DocumentPath;
ProjectItemStreamMode iMode = (ProjectItemStreamMode)0;
//<==converter_chokes_here
Stream sDocumentStream = base.Document.ProjectItem.GetStream(iMode);
return new MyFirstAddInForm(this, sDocumentPath, sDocumentName,
sDocumentStream);
}
.....
 
Protected overloads Function CreateAddInForm() as AddInForm
Dim sDocumentName As String = base.Document.DocumentName
Dim sDocumentPath As String = base.Document.DocumentPath
Dim iMode As ProjectItemStreamMode = ctype(0,ProjectItemStreamMode)
Dim sDocumentStream As Stream =
base.Document.ProjectItem.GetStream(iMode)
return new MyFirstAddInForm(Me, sDocumentPath, sDocumentName,
sDocumentStream)
End Function

Not tested but grammatically correct

Bismark
 
that works !

thanks

Bismark Prods said:
Protected overloads Function CreateAddInForm() as AddInForm
Dim sDocumentName As String = base.Document.DocumentName
Dim sDocumentPath As String = base.Document.DocumentPath
Dim iMode As ProjectItemStreamMode = ctype(0,ProjectItemStreamMode)
Dim sDocumentStream As Stream =
base.Document.ProjectItem.GetStream(iMode)
return new MyFirstAddInForm(Me, sDocumentPath, sDocumentName,
sDocumentStream)
End Function

Not tested but grammatically correct

Bismark
 
Back
Top