Click here to Skip to main content
15,886,919 members
Home / Discussions / C#
   

C#

 
GeneralRe: Error: Interfaces cannot contain fields Pin
Joni_7828-Nov-12 0:52
Joni_7828-Nov-12 0:52 
GeneralRe: Error: Interfaces cannot contain fields Pin
Pete O'Hanlon28-Nov-12 1:08
mvePete O'Hanlon28-Nov-12 1:08 
GeneralAbout URL Pin
Varsha R27-Nov-12 20:42
Varsha R27-Nov-12 20:42 
GeneralRe: About URL Pin
Pete O'Hanlon27-Nov-12 20:52
mvePete O'Hanlon27-Nov-12 20:52 
GeneralRe: About URL Pin
girishru12328-Nov-12 22:23
girishru12328-Nov-12 22:23 
QuestionHow do you programmatically expand a url link to its true location? Pin
Xarzu27-Nov-12 20:25
Xarzu27-Nov-12 20:25 
AnswerRe: How do you programmatically expand a url link to its true location? Pin
Bernhard Hiller27-Nov-12 22:11
Bernhard Hiller27-Nov-12 22:11 
QuestionConverted VB.NET to C# With Error Pin
daveofgv27-Nov-12 10:40
daveofgv27-Nov-12 10:40 
I am a VB.NET Programmer learning C#. One of my applications I transfered over to C# via an online converion tool. I am receiving an error which I do not see why it's causing an error.

What I have now is:

C#
try {

			if (System.IO.File.Exists(srcedest) == false) {
				//My.Computer.FileSystem.RenameFile((dest), newName:=sheet.Cells(row, 14).value & "_" & sheet.Cells(row, 15).value)
                My.Computer.FileSystem.RenameFile((dest), newName) sheet.Cells(row, 1).value;
				// & "_" & sheet.Cells(row, 2).value & "_" & sheet.Cells(row, 3).value)

			}

		} catch (Exception ex) {
			txtLog3.AppendText(sheet.Cells(row, 1).value);
			// & "_" & sheet.Cells(row, 3).value & vbCrLf)
		}


With the error of "expecting ;" at the "sheet" in My.Computer.FileSystem.RenameFile((dest), newName) sheet.Cells(row, 1).value;

Why would this cause an error since you don't put a ";" until the end of a statement?

Thanks in advanced.

daveofgv

modified 27-Nov-12 16:52pm.

AnswerRe: Converted VB.NET to C# With Error Pin
PIEBALDconsult27-Nov-12 12:14
mvePIEBALDconsult27-Nov-12 12:14 
GeneralRe: Converted VB.NET to C# With Error Pin
Eddy Vluggen27-Nov-12 13:38
professionalEddy Vluggen27-Nov-12 13:38 
AnswerRe: Converted VB.NET to C# With Error Pin
Pete O'Hanlon27-Nov-12 20:49
mvePete O'Hanlon27-Nov-12 20:49 
AnswerRe: Converted VB.NET to C# With Error Pin
Bernhard Hiller27-Nov-12 22:19
Bernhard Hiller27-Nov-12 22:19 
AnswerRe: Converted VB.NET to C# With Error Pin
GREG_DORIANcod28-Nov-12 10:10
professionalGREG_DORIANcod28-Nov-12 10:10 
QuestionUrgent Help Pin
Asma AlShehhi27-Nov-12 10:27
Asma AlShehhi27-Nov-12 10:27 
AnswerRe: Urgent Help Pin
R. Giskard Reventlov27-Nov-12 12:19
R. Giskard Reventlov27-Nov-12 12:19 
AnswerRe: Urgent Help Pin
Eddy Vluggen27-Nov-12 12:55
professionalEddy Vluggen27-Nov-12 12:55 
GeneralRe: Urgent Help Pin
OriginalGriff27-Nov-12 21:08
mveOriginalGriff27-Nov-12 21:08 
AnswerRe: Urgent Help Pin
fjdiewornncalwe28-Nov-12 11:54
professionalfjdiewornncalwe28-Nov-12 11:54 
AnswerRe: Urgent Help Pin
BobJanova28-Nov-12 23:16
BobJanova28-Nov-12 23:16 
QuestionHow to prevent multiple button clicks Pin
MichCl27-Nov-12 10:15
MichCl27-Nov-12 10:15 
AnswerRe: How to prevent multiple button clicks Pin
Eddy Vluggen27-Nov-12 12:48
professionalEddy Vluggen27-Nov-12 12:48 
GeneralRe: How to prevent multiple button clicks Pin
MichCl28-Nov-12 8:31
MichCl28-Nov-12 8:31 
AnswerRe: How to prevent multiple button clicks Pin
lukeer27-Nov-12 20:17
lukeer27-Nov-12 20:17 
GeneralRe: How to prevent multiple button clicks Pin
MichCl28-Nov-12 7:40
MichCl28-Nov-12 7:40 
GeneralRe: How to prevent multiple button clicks Pin
MichCl28-Nov-12 7:41
MichCl28-Nov-12 7:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.