Discussion:
VB.Net to C# Convertor for asp.net 2.0
Jeff
2007-05-03 21:18:24 UTC
Permalink
I have a few web projects that were written by someone else in


I have a few web projects that were written by someone else in asp.net 2.0 with VB.Net and i would like to convert them to c#. These projects are prettty simple, but there is a lot of code; they are not even broken out into mulitple tiers, there are a couple classes thrown in the app_code folder. Anyone have any exprience with the convertor products out there? I know there are a few, but i would rather safe the efforts of research and testing, and only look at the ones that work well. Please send me some referalls. Thanks.


===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Clark, Michael (OFM)
2007-05-04 17:54:45 UTC
Permalink
Shawn Wildermuth (MVP)
2007-05-04 18:02:42 UTC
Permalink
Jacob Mattison
2007-05-04 18:06:16 UTC
Permalink
Clark, Michael (OFM)
2007-05-04 18:30:22 UTC
Permalink
Shawn Wildermuth (MVP)
2007-05-04 18:33:50 UTC
Permalink
Patrick Steele
2007-05-04 18:34:05 UTC
Permalink
Efran Cobisi
2007-05-07 07:43:35 UTC
Permalink
Hi Clark,

Could you assure that you set up the appropriate smtp server
informations in the right place inside your web.config file (i.e.
/configuration/system.net/mailSettings/smtp/network)?
A common error consists in leaving the original System.Web.Mail settings
inside the web.config file and forgetting to set up the ones needed by
the (not so) new System.Net.Mail.

Also check out [1] and [2], which have loads of information about both
the systems.

[1] http://www.systemwebmail.com/
[2] http://www.systemnetmail.com/

HTH,

--
Efran Cobisi
http://www.cobisi.com

Clark, Michael (OFM) wrote:
> I've tried fully qualifying the server, using the IP address, and
> setting the server info via the configuration file. No luck; same
> errors.
>
> -----Original Message-----
> From: Discussion of building .NET applications targeted for the Web
> [mailto:DOTNET-***@DISCUSS.DEVELOP.COM] On Behalf Of Jacob Mattison
> Sent: Friday, May 04, 2007 11:06 AM
> To: DOTNET-***@DISCUSS.DEVELOP.COM
> Subject: Re: [DOTNET-WEB] Using System.Net.Mail
>
> That looks right to me. In my case I have to use the fully qualified
> name of the SMTP server, so if the server is called smtp1, I have to use
> "smtp1.jwu.edu". Perhaps that would help?
>
> Alternately, if you weren't specifying an external mail server
> previously, it may have been using a local SMTP server. Perhaps there's
> a firewall setting on the SMTP server that's preventing a connection
> from the machine this is running on?
>
> I don't think it's a problem in your code.
>
>
>
> -----Original Message-----
>
> string to = "***@fake.com";
> string from = "***@fake.com";
> MailMessage message = new MailMessage(from, to); message.Subject =
> "Using the new SMTP client."; message.Body = @"Using this new feature,
> you can send an e-mail message from an application very easily.";
> SmtpClient client = new SmtpClient(Server); client.UseDefaultCredentials
> = true; client.Send(message);
>
> When the Send is executed this exception is raised:
> "An established connection was aborted by the software in your host
> machine "
>
> Looking further, the status code given is "GeneralFailure", the
> exception message is "Failure sending mail." and the inner exception
> message is "Unable to connect to the remote server".
>
> The problem may or may not be centered around the server name. It's a
> server on our intranet, and I have tried both its name and its IP
> address, but no joy.
>
> ===================================
> This list is hosted by DevelopMentor(r) http://www.develop.com
>
> View archives and manage your subscription(s) at
> http://discuss.develop.com
>
> ===================================
> This list is hosted by DevelopMentor® http://www.develop.com
>
> View archives and manage your subscription(s) at http://discuss.develop.com
>

--
Efran Cobisi
Technical Project Leader
MCP, MCTS: SQL Server 2005
***@qbgroup.it <mailto:***@qbgroup.it>



QBGROUP spa
Corso del Popolo, 8/C - 35131 Padova - Italy
tel. +39 049.8763444 - fax +39 049.8787700
www.qbgroup.it <http://www.qbgroup.it>

===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Booth, Bill
2007-05-04 19:21:28 UTC
Permalink
dave wanta
2007-05-04 21:08:14 UTC
Permalink
Hi,

Usually, there are 2 main solutions to this problem.

1) You have a virus scanner that is stopping outgoing port 25 connections.
You need to configure your virus scanner to allow your exe (even if it is
the aspnet_wp.exe) to allow it to send email.

2) You have a firewall that is blocking your connection. Again, configure
it to allow outgoing port 25 connections.

Cheers!
Dave
----- Original Message -----
From: "Clark, Michael (OFM)" <***@OFM.WA.GOV>
To: <DOTNET-***@DISCUSS.DEVELOP.COM>
Sent: Friday, May 04, 2007 12:54 PM
Subject: [DOTNET-WEB] Using System.Net.Mail



I'm going out of my mind trying to get System.Net.Mail to work in an
app, but am having no joy. I was using System.Web.Mail, and the
following code works like a charm:

MailMessage mm = new MailMessage()
mm.To = "***@fake.com";
mm.From = "***@fake.com";
mm.Body = "Just testing this";
mm.Subject = "Testing 123";

SmtpMail.Send(mm);

VS2005 says it's obsolete, so I'm trying to use the "new and improved"
methods.

I look at the sample code in MSDN on using the Send method in
System.Net.Mail.SmtpClient as found here:

http://msdn2.microsoft.com/en-us/library/swas0fwc.aspx

And the code that I am attempting to execute is:

string to = "***@fake.com";
string from = "***@fake.com";
MailMessage message = new MailMessage(from, to);
message.Subject = "Using the new SMTP client.";
message.Body = @"Using this new feature, you can send an e-mail message
from an application very easily.";
SmtpClient client = new SmtpClient(Server);
client.UseDefaultCredentials = true;
client.Send(message);

When the Send is executed this exception is raised:
"An established connection was aborted by the software in your host
machine "

Looking further, the status code given is "GeneralFailure", the
exception message is "Failure sending mail." and the inner exception
message is "Unable to connect to the remote server".

The problem may or may not be centered around the server name. It's a
server on our intranet, and I have tried both its name and its IP
address, but no joy.

Does anyone have any suggestions?

===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com

===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Christopher Reed
2007-05-07 11:23:41 UTC
Permalink
Typical, I find that the anti-virus software on the SMTP server is blocking port
25. If you SMTP server is different from when you use System.Web.Mail and
System.Net.Mail, then look at your virus scanner settings.

--------------------------------------------------------------------------------
---
Christopher Reed
"The oxen are slow, but the earth is patient."


>|-----Original Message-----
>|From: Discussion of building .NET applications targeted for the Web
[mailto:DOTNET-***@DISCUSS.DEVELOP.COM] On Behalf Of Clark, Michael (OFM)
>|Sent: Friday, May 04, 2007 12:55 PM
>|To: DOTNET-***@DISCUSS.DEVELOP.COM
>|Subject: [DOTNET-WEB] Using System.Net.Mail
>|
>|
>|I'm going out of my mind trying to get System.Net.Mail to work in an app, but
am having no joy. I was using System.Web.Mail, and the following code works
like a charm:
>|
>|MailMessage mm = new MailMessage()
>|mm.To = "***@fake.com";
>|mm.From = "***@fake.com";
>|mm.Body = "Just testing this";
>|mm.Subject = "Testing 123";
>|
>|SmtpMail.Send(mm);
>|
>|VS2005 says it's obsolete, so I'm trying to use the "new and improved"
methods.
>|
>|I look at the sample code in MSDN on using the Send method in
System.Net.Mail.SmtpClient as found here:
>|
>|http://msdn2.microsoft.com/en-us/library/swas0fwc.aspx
>|
>|And the code that I am attempting to execute is:
>|
>|string to = "***@fake.com";
>|string from = "***@fake.com";
>|MailMessage message = new MailMessage(from, to);
>|message.Subject = "Using the new SMTP client.";
>!message.Body = @"Using this new feature, you can send an e-mail message from
an application very easily.";
>!SmtpClient client = new SmtpClient(Server);
>!client.UseDefaultCredentials = true;
>|client.Send(message);
>|
>|When the Send is executed this exception is raised: "An established connection
was aborted by the software in your host machine "
>|
>|Looking further, the status code given is "GeneralFailure", the exception
message is "Failure sending mail." and the inner exception message is "Unable to
connect to the remote server".
>|
>|The problem may or may not be centered around the server name. It's a server
on our intranet, and I have tried both its name and its IP address, but no joy.

>|
>|Does anyone have any suggestions?

No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.467 / Virus Database: 269.6.5/792 - Release Date: 5/6/2007 9:01 PM

===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Alex Ivanoff
2007-05-04 18:48:16 UTC
Permalink
What is your smtp server?

===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Ivanoff, Alex
2007-05-04 21:06:05 UTC
Permalink
Adam Tuliper
2007-05-05 01:37:15 UTC
Permalink
Loading...