From: Earl Partridge on
If there's a newgroup for this subject, please point me to it...
Is it possible to set the font size of the body of the text?
Earl
From: Anthony Jones on

"Earl Partridge" <earlpNG(a)pearnet.com> wrote in message
news:ujTeEiNyIHA.2208(a)TK2MSFTNGP04.phx.gbl...
>If there's a newgroup for this subject, please point me to it...
>Is it possible to set the font size of the body of the text?

First ditch CDONTS (its deprecated) and use CDOSYS instead. Here is an
exampel of sending an
email with CDOSYS:-

Const cdoSendUsingMethod =
"http://schemas.microsoft.com/cdo/configuration/sendusing"
Const cdoSMTPServer =
"http://schemas.microsoft.com/cdo/configuration/smtpserver"
Const cdoSMTPServerPickupDirectory =
"http://schemas.microsoft.com/cdo/configuration/smtpserverpickupdirectory"
Const cdoSMTPServerPort =
"http://schemas.microsoft.com/cdo/configuration/smtpserverport"

Const cdoSendUsingPickup = 1
Const cdoSendUsingPort = 2

Dim oMsg : Set oMsg = CreateObject("CDO.Message")
Dim oConfig : Set oConfig = CreateObject("CDO.Configuration")

With oConfig.Fields
.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Item(cdoSMTPServer) = "mysmtp.myserver.com"
.Item(cdoSMTPServerPort) = 25
.Update
End With

oMsg.From = "Me <me(a)mymail.myserver.com>"
oMsg.To = "Bloke <bloke(a)somewere.com>"
oMsg.Subject = "Test"
oMsg.HTMLBody = "<html><body style="font-size:14pt">Hello
World</body></html>"
Set oMsg.Configuration = oConfig

oMsg.Send


Note the HTMLBody uses a style that defines the font size.

Of course this assumes you aren't asking how to make the size of font in a
plain text message the bigger. The answer to that would be; you can't use a
HTMLBody instead.


--
Anthony Jones - MVP ASP/ASP.NET


From: Old Pedant on
A goof in that, Anthony:

oMsg.HTMLBody = "<html><body style="font-size:14pt">Hello
World</body></html>"

Ummm...that NEEDS to be

oMsg.HTMLBody = "<html><body style=""font-size:14pt"">Hello
World</body></html>"

Doubled quotes to embed them, of course.


"Anthony Jones" wrote:

>
> "Earl Partridge" <earlpNG(a)pearnet.com> wrote in message
> news:ujTeEiNyIHA.2208(a)TK2MSFTNGP04.phx.gbl...
> >If there's a newgroup for this subject, please point me to it...
> >Is it possible to set the font size of the body of the text?
>
> First ditch CDONTS (its deprecated) and use CDOSYS instead. Here is an
> exampel of sending an
> email with CDOSYS:-
>
> Const cdoSendUsingMethod =
> "http://schemas.microsoft.com/cdo/configuration/sendusing"
> Const cdoSMTPServer =
> "http://schemas.microsoft.com/cdo/configuration/smtpserver"
> Const cdoSMTPServerPickupDirectory =
> "http://schemas.microsoft.com/cdo/configuration/smtpserverpickupdirectory"
> Const cdoSMTPServerPort =
> "http://schemas.microsoft.com/cdo/configuration/smtpserverport"
>
> Const cdoSendUsingPickup = 1
> Const cdoSendUsingPort = 2
>
> Dim oMsg : Set oMsg = CreateObject("CDO.Message")
> Dim oConfig : Set oConfig = CreateObject("CDO.Configuration")
>
> With oConfig.Fields
> .Item(cdoSendUsingMethod) = cdoSendUsingPort
> .Item(cdoSMTPServer) = "mysmtp.myserver.com"
> .Item(cdoSMTPServerPort) = 25
> .Update
> End With
>
> oMsg.From = "Me <me(a)mymail.myserver.com>"
> oMsg.To = "Bloke <bloke(a)somewere.com>"
> oMsg.Subject = "Test"
> oMsg.HTMLBody = "<html><body style="font-size:14pt">Hello
> World</body></html>"
> Set oMsg.Configuration = oConfig
>
> oMsg.Send
>
>
> Note the HTMLBody uses a style that defines the font size.
>
> Of course this assumes you aren't asking how to make the size of font in a
> plain text message the bigger. The answer to that would be; you can't use a
> HTMLBody instead.
>
>
> --
> Anthony Jones - MVP ASP/ASP.NET
>
>
>
From: Earl Partridge on
Thanks, would I need to get my hosting service to do any configuration
change to accept CDOSYS?
Earl

"Anthony Jones" <Ant(a)yadayadayada.com> wrote in message
news:e8aTfYOyIHA.4864(a)TK2MSFTNGP06.phx.gbl...
>
> "Earl Partridge" <earlpNG(a)pearnet.com> wrote in message
> news:ujTeEiNyIHA.2208(a)TK2MSFTNGP04.phx.gbl...
>>If there's a newgroup for this subject, please point me to it...
>>Is it possible to set the font size of the body of the text?
>
> First ditch CDONTS (its deprecated) and use CDOSYS instead. Here is an
> exampel of sending an
> email with CDOSYS:-
>
> Const cdoSendUsingMethod =
> "http://schemas.microsoft.com/cdo/configuration/sendusing"
> Const cdoSMTPServer =
> "http://schemas.microsoft.com/cdo/configuration/smtpserver"
> Const cdoSMTPServerPickupDirectory =
> "http://schemas.microsoft.com/cdo/configuration/smtpserverpickupdirectory"
> Const cdoSMTPServerPort =
> "http://schemas.microsoft.com/cdo/configuration/smtpserverport"
>
> Const cdoSendUsingPickup = 1
> Const cdoSendUsingPort = 2
>
> Dim oMsg : Set oMsg = CreateObject("CDO.Message")
> Dim oConfig : Set oConfig = CreateObject("CDO.Configuration")
>
> With oConfig.Fields
> .Item(cdoSendUsingMethod) = cdoSendUsingPort
> .Item(cdoSMTPServer) = "mysmtp.myserver.com"
> .Item(cdoSMTPServerPort) = 25
> .Update
> End With
>
> oMsg.From = "Me <me(a)mymail.myserver.com>"
> oMsg.To = "Bloke <bloke(a)somewere.com>"
> oMsg.Subject = "Test"
> oMsg.HTMLBody = "<html><body style="font-size:14pt">Hello
> World</body></html>"
> Set oMsg.Configuration = oConfig
>
> oMsg.Send
>
>
> Note the HTMLBody uses a style that defines the font size.
>
> Of course this assumes you aren't asking how to make the size of font in a
> plain text message the bigger. The answer to that would be; you can't use
> a
> HTMLBody instead.
>
>
> --
> Anthony Jones - MVP ASP/ASP.NET
>
>


From: Mike Brind [MVP] on
If your hoster is using Win 2k or above, then no. CDO became the default
mailing component from Win 2k. In fact, you are more likely to have
problems getting them to set up CDONTS.

--
Mike Brind
Microsoft MVP - ASP/ASP.NET


"Earl Partridge" <earlpNG(a)pearnet.com> wrote in message
news:ujtzFBiyIHA.5820(a)TK2MSFTNGP04.phx.gbl...
> Thanks, would I need to get my hosting service to do any configuration
> change to accept CDOSYS?
> Earl
>
> "Anthony Jones" <Ant(a)yadayadayada.com> wrote in message
> news:e8aTfYOyIHA.4864(a)TK2MSFTNGP06.phx.gbl...
>>
>> "Earl Partridge" <earlpNG(a)pearnet.com> wrote in message
>> news:ujTeEiNyIHA.2208(a)TK2MSFTNGP04.phx.gbl...
>>>If there's a newgroup for this subject, please point me to it...
>>>Is it possible to set the font size of the body of the text?
>>
>> First ditch CDONTS (its deprecated) and use CDOSYS instead. Here is an
>> exampel of sending an
>> email with CDOSYS:-
>>
>> Const cdoSendUsingMethod =
>> "http://schemas.microsoft.com/cdo/configuration/sendusing"
>> Const cdoSMTPServer =
>> "http://schemas.microsoft.com/cdo/configuration/smtpserver"
>> Const cdoSMTPServerPickupDirectory =
>> "http://schemas.microsoft.com/cdo/configuration/smtpserverpickupdirectory"
>> Const cdoSMTPServerPort =
>> "http://schemas.microsoft.com/cdo/configuration/smtpserverport"
>>
>> Const cdoSendUsingPickup = 1
>> Const cdoSendUsingPort = 2
>>
>> Dim oMsg : Set oMsg = CreateObject("CDO.Message")
>> Dim oConfig : Set oConfig = CreateObject("CDO.Configuration")
>>
>> With oConfig.Fields
>> .Item(cdoSendUsingMethod) = cdoSendUsingPort
>> .Item(cdoSMTPServer) = "mysmtp.myserver.com"
>> .Item(cdoSMTPServerPort) = 25
>> .Update
>> End With
>>
>> oMsg.From = "Me <me(a)mymail.myserver.com>"
>> oMsg.To = "Bloke <bloke(a)somewere.com>"
>> oMsg.Subject = "Test"
>> oMsg.HTMLBody = "<html><body style="font-size:14pt">Hello
>> World</body></html>"
>> Set oMsg.Configuration = oConfig
>>
>> oMsg.Send
>>
>>
>> Note the HTMLBody uses a style that defines the font size.
>>
>> Of course this assumes you aren't asking how to make the size of font in
>> a
>> plain text message the bigger. The answer to that would be; you can't
>> use a
>> HTMLBody instead.
>>
>>
>> --
>> Anthony Jones - MVP ASP/ASP.NET
>>
>>
>
>


 |  Next  |  Last
Pages: 1 2 3 4
Prev: Datagridview Won't stay updated
Next: Website Admin Tool