Windows Vista Tips

Windows Vista Tips > Newsgroups > Windows Server > Scripting > Provide me steps to run automate outlook signature

Reply
Thread Tools Display Modes

Provide me steps to run automate outlook signature

 
 
Simi Brig
Guest
Posts: n/a

 
      03-03-2010
Many thanks for great effort!!

I went through the attached script and same script used to at my domain but its not supposed to worked out.

Then used for stand alone machine but no contains in the signature.

I am easy to run but without contains like name, phone nothing as come.

Could u assist me to how to execute and way to run of this script?


Many Thanks,
Simi Brig.



xizero wrote:

just add thisobjSelection.Font.name = "Arial"objSelection.Font.
18-Oct-07

just add this
objSelection.Font.name = "Arial"
objSelection.Font.Size = 12
objSelection.Font.Bold = True
in where the text is being typed ... like so

On Error Resume Next

Set objSysInfo = CreateObject("ADSystemInfo")

strUser = objSysInfo.UserName
Set objUser = GetObject("LDAP://" & strUser)

strTitle = objUser.Title
strName = objUser.FullName
strDepartment = objUser.Department
strCompany = objUser.Company
strPhone = objUser.telephoneNumber

Set objWord = CreateObject("Word.Application")

Set objDoc = objWord.Documents.Add()
Set objSelection = objWord.Selection

Set objEmailOptions = objWord.EmailOptions
Set objSignatureObject = objEmailOptions.EmailSignature

Set objSignatureEntries = objSignatureObject.EmailSignatureEntries

objSelection.Font.name = "Arial"
objSelection.Font.Size = 12
objSelection.Font.Bold = True
objSelection.TypeText strTitle & ", " & strName
objSelection.TypeParagraph()
objSelection.Font.Bold = False
objSelection.TypeText strDepartment
objSelection.TypeParagraph()
objSelection.TypeText strCompany
objSelection.TypeParagraph()
objSelection.TypeText strPhone
objSelection.TypeParagraph()



Set objSelection = objDoc.Range()

objSignatureEntries.Add "AD Signature", objSelection
objSignatureObject.NewMessageSignature = "AD Signature"
objSignatureObject.ReplyMessageSignature = "AD Signature"

objDoc.Saved = True
objWord.Quit


--
xizero
------------------------------------------------------------------------
xizero's Profile: http://forums.techarena.in/member.php?userid=33203
View this thread: http://forums.techarena.in/showthread.php?t=733065

http://forums.techarena.in

Previous Posts In This Thread:

On Friday, April 20, 2007 4:58 PM
Joh wrote:

Outllok 2003 Signature script
I came across the script below in an issue of TechNet and have been testing
it ever since so that I can actually use it. I'm not very familiar with
scripting, but from playing with the code in this was able to figure out what
is what. I would like to tweak it to do a couple more things but have not had
much luck figuring these options out. If possible I???d like to have the e-mail
address be an actual link that will bring up a new e-mail with the address in
the ???To:??? field, I???d like to insert a logo and have it link to a website,
insert another phone number (mobile), show the address (or another filed from
AD that I could put the address in) and last but not least on the cosmetic
side I???d like to use a different font style and color.

Thanks for any help!

Here the code I have




On Error Resume Next

Set objSysInfo = CreateObject("ADSystemInfo")

strUser = objSysinfo.UserName
Set objUser = GetObject("LDAP:// "& strUser)

strName = objUser.FullName
strTitle = objUser.Title
strDepartment = objUser.Department
strCompany = objUser.Company
strPhone = objUser.TelephoneNumber
strOffice = objUser.Office
strMail = objUser.mail

Set objWord = CreateObject("Word.Application")
objWord.Visible = false

Set objDoc = objWord.Documents.Add()
Set objSelection = objWord.Selection

Set objEmailOptions = objWord.EmailOptions
Set objSignatureObject = objEmailOptions.EmailSignature

Set objSignatureEntries = objSignatureObject.EmailSignatureEntries

objSelection.TypeText strName
objSelection.TypeParagraph()
objSelection.TypeText strTitle
objSelection.TypeParagraph()
objSelection.TypeText strDepartment
objSelection.TypeParagraph()
objSelection.TypeText strCompany
objSelection.TypeParagraph()
objSelection.TypeText strPhone
objSelection.TypeParagraph()
objSelection.TypeText strmail

Set objSelection=objDoc.Range()

objSignatureEntries.Add "AD Signature", objSelection
objSignatureObject.NewMessageSignature = "AD Signature"
objSignatureObject.ReplyMessageSignature = "AD Signature"

objDoc.Saved = true
objWord.Quit


--
Thanks,
John

On Monday, April 23, 2007 11:13 AM
Joseph M. wrote:

John,Based on the code below, you're starting to dive into VB for Apps
John,

Based on the code below, you're starting to dive into VB for Apps (creating
a word doc for your signature). I don't have a simple answer for you via
specific code, but recomened you take a look at the VB Editor (macro editor)
interface within Word or Outlook (Alt+F11). It's really a lot more than
just a macro editor. You can open up the object libraries for each app and
get some good code examples to accomplish what you are looking for.
Depending one which app you open it within, Word or Outlook, you'd most
likely need to add the appropriate reference libraries. This can be done
via the Tools/References menu. Ex., if in Outlook you will need to add
Word. In OFF2K7, Words likbraries are refered to as "Microsoft Word 12.0
Object Library".

If you are looking for a quicker solution, you may also want to check out
Desktop Authority, www.scriptlogic.com/da. It will automatically leverage
user inforamtion in AD to provide some great Outlook signature templates.
Also has a built in editor which allows you to setup the email address as a
mailto hyperlink as well as adjust font size, type, color...
http://www.scriptlogic.com/products/...ok-General.asp

Best,

--
Joseph Majzoub
Systems Engineer
ScriptLogic Corporation
www.scriptlogic.com



"John" <> wrote in message
news:99EF6A85-5939-457B-817A-...

On Thursday, October 18, 2007 2:47 AM
xizero wrote:

just add thisobjSelection.Font.name = "Arial"objSelection.Font.
just add this
objSelection.Font.name = "Arial"
objSelection.Font.Size = 12
objSelection.Font.Bold = True
in where the text is being typed ... like so

On Error Resume Next

Set objSysInfo = CreateObject("ADSystemInfo")

strUser = objSysInfo.UserName
Set objUser = GetObject("LDAP://" & strUser)

strTitle = objUser.Title
strName = objUser.FullName
strDepartment = objUser.Department
strCompany = objUser.Company
strPhone = objUser.telephoneNumber

Set objWord = CreateObject("Word.Application")

Set objDoc = objWord.Documents.Add()
Set objSelection = objWord.Selection

Set objEmailOptions = objWord.EmailOptions
Set objSignatureObject = objEmailOptions.EmailSignature

Set objSignatureEntries = objSignatureObject.EmailSignatureEntries

objSelection.Font.name = "Arial"
objSelection.Font.Size = 12
objSelection.Font.Bold = True
objSelection.TypeText strTitle & ", " & strName
objSelection.TypeParagraph()
objSelection.Font.Bold = False
objSelection.TypeText strDepartment
objSelection.TypeParagraph()
objSelection.TypeText strCompany
objSelection.TypeParagraph()
objSelection.TypeText strPhone
objSelection.TypeParagraph()



Set objSelection = objDoc.Range()

objSignatureEntries.Add "AD Signature", objSelection
objSignatureObject.NewMessageSignature = "AD Signature"
objSignatureObject.ReplyMessageSignature = "AD Signature"

objDoc.Saved = True
objWord.Quit


--
xizero
------------------------------------------------------------------------
xizero's Profile: http://forums.techarena.in/member.php?userid=33203
View this thread: http://forums.techarena.in/showthread.php?t=733065

http://forums.techarena.in


Submitted via EggHeadCafe - Software Developer Portal of Choice
Sending SMTP email from within BizTalk Orchestration
http://www.eggheadcafe.com/tutorials...il-from-w.aspx
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
windows explorer not responding after right clicking - error Woodzys Windows Vista General Discussion 4 11-07-2009 12:47 PM
Hours are offset when synchronizing Outlook 2003 and Windows Mobile 6 Nathan Sokalski ActiveSync 10 02-12-2009 01:27 AM
Outlook MAPI32.DLL Error Bluebotle Windows Vista Installation 6 02-12-2008 01:28 AM
Re: Activesync 4.2 & Outlook Connector for Lotus Notes (85010014) Ian ActiveSync 0 09-25-2006 10:31 PM
Re: Activesync on New PDA Will Not Sync With Outlook Chris De Herrera ActiveSync 1 12-11-2004 02:30 AM



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59