Sunday, November 22, 2009

Attack Of The 7 Year Old PC

Success! My PC's up and running again after buying a generic power supply ($40) from CyberActive at Sengkang Compass Point.

It's been down for almost a year as I simply couldn't find the time to go and buy one.

I have totally forgotten what crappy specs it has.

Gotta get some new parts so I can install Windows 7 RC and enjoy Aero.

2 x 1GB DDR SDRAM 266MHz at $50 each
Currently, BIOS says I have 768MB RAM.

Largest 3.5" IDE HDD I can find:
500GB at $80

A new LAN card $20
I have no idea where my current LAN card or it's driver comes from. Windows 7 and Google can't find the drivers either

That's $200 to run an OS that WILL die in March 2010

Now I'm wondering if it's worth it

Monday, November 16, 2009

Work Stuff: System.Net.Mail Notes

Spent a rainy afternoon wrestling with Windows Server 2008, IIS 7

First Error:
System.Net.Mail.SmtpException: Failure sending mail. ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: No connection could be made because the target machine actively refused it 127.0.0.1:25
at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress)
at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Int32 timeout, Exception& exception)
--- End of inner exception stack trace ---
at System.Net.ServicePoint.GetConnection(PooledStream PooledStream, Object owner, Boolean async, IPAddress& address, Socket& abortSocket, Socket& abortSocket6, Int32 timeout)
at System.Net.PooledStream.Activate(Object owningObject, Boolean async, Int32 timeout, GeneralAsyncDelegate asyncCallback)
at System.Net.PooledStream.Activate(Object owningObject, GeneralAsyncDelegate asyncCallback)
at System.Net.ConnectionPool.GetConnection(Object owningObject, GeneralAsyncDelegate asyncCallback, Int32 creationTimeout)
at System.Net.Mail.SmtpConnection.GetConnection(String host, Int32 port)
at System.Net.Mail.SmtpClient.Send(MailMessage message)
--- End of inner exception stack trace ---
at System.Net.Mail.SmtpClient.Send(MailMessage message)
at webservice.sendNotification(Int32 iAppID, String strFromUID, String strToUID, String strMessage) in c:\inetpub\wwwroot\webservice.ashx:line 1001

Solution: Go to Services and make sure the SMTP Service is running (Don't trust the Feature Manager)

Second Problem:
System.Net.Mail.SmtpFailedRecipientsException: Unable to send to all recipients. ---> System.Net.Mail.SmtpFailedRecipientException: Mailbox unavailable. The server response was: 5.7.1 Unable to relay for nickfurry@live.com
--- End of inner exception stack trace ---
at System.Net.Mail.SmtpTransport.SendMail(MailAddress sender, MailAddressCollection recipients, String deliveryNotify, SmtpFailedRecipientException& exception)
at System.Net.Mail.SmtpClient.Send(MailMessage message)
at webservice.sendNotification(Int32 iAppID, String strFromUID, String strToUID, String strMessage) in c:\inetpub\wwwroot\webservice.ashx:line 1001

Solution:
SmtpClient objClient = new SmtpClient();
objClient.DeliveryMethod = SmtpDeliveryMethod.PickupDirectoryFromIis;
objClient.Send(objMail);

The Delivery Method is the key.

Wednesday, November 11, 2009

Heroic Dinosaurs


The real reason they're extinct