Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - timkool

Pages: [1]
1
Off-Topic / Need help sending email from webpage
« on: 2009-05-15, 05:57:17 AM »
Hi,
I am trying to send emails from my asp page with cdo but keep getting the following error:

"An error occurred on the server when processing the URL. Please contact the system administrator."

The host of the website is btconnect and i have phoned them to check the server settings which they say are correct. My code is as follows:

Code:

Set oMail = Server.CreateObject("CDO.Message")
   Set iConf = Server.CreateObject("CDO.Configuration")
   Set Flds = iConf.Fields
   iConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = cdoSendUsingPort
   iConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "mail.btconnect.com"
   iConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 10
   iConf.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25

   iConf.Fields.Update
   Set oMail.Configuration = iConf
   oMail.To       = "kudutravel@btconnect.com"
   oMail.From       = "kudutravel@btconnect.com"
   oMail.Subject       = "Test"
   oMail.HTMLBody       = "Test Message"
   
   oMail.Send
   Set iConf = Nothing
   Set Flds = Nothing

Any help or advice would be appreciated

Regards
JD




www.floatingtank.at
methadrostenol

2
Script / Phone Conversations
« on: 2009-05-15, 05:56:05 AM »
I was wondering how to properly format a phone conversation in which one character is talking to another, and the scene would cut between shots of each character in two different places.

Would I put something along the lines of 'we cut between the locations of each person as they speak'?
I'M GOLDEN CLOCK HA HA HA






www.floatingtank.at
methadrostenol

3
Off-Topic / inserting data into sql database
« on: 2009-05-15, 05:53:46 AM »
 Hello,


I'm new here and I have just started developing websites using VB ASP 3.5. Anyway, my questions is:

- In C# I can insert new data into tables using the below commands:

DataSetTableAdapters.TableNameTableADapter AddData = new DataSetTableAdapters.TableNameTableADapter()

AddData.Insert(
FirstEntry,
SecondData,
ThirdData)


Now im trying to do this in VB but its not working! Can someone please tell me how to do it?

I've gone through a lot of VB ASP books but they only tell you how to get data (SQL SOURCE, GRIDVIEW ..etc) and not how to add data.

Any advise appreciated. Thanks..




There are a couple of ways of doing this, but I find the following the easiest.

Code:

Dim Conn
Conn = "DSN=myDataSource" 'or a full connection string

Set rs = Server.CreateObject("ADODB.RecordSet")
SQL = "SELECT TOP 1 column1, column2 FROM myTable"
rs.Open SQL, Conn, 1, 3

rs.AddNew
rs("column1") = "SomeData"
rs("column2") = "SomeOtherData"
rs.Update

Set rs = Nothing

Believe it or not, that is all you need!





www.floatingtank.at
methadrostenol

Pages: [1]