How to insert screenshot on to the body of outlook?
-1 how to use insert-picture tab in new email outlook to
insert image in the body.
Suggest something.......
Answer Posted / sanjay kardile
Hello,
You can try the below code. Hope this is help full.
Set objOutlookMail = CreateObject("Outlook.Application")
Set myMail = objOutlookMail.CreateItem(0)
myMail.Display
Set myMailProperty = objOutlookMail.ActiveInspector
If myMailProperty.IsWordMail = "True" Then
Set myDoc = myMailProperty.WordEditor
' Insert text and Image in the body of the email
myDoc.Range.InsertBefore Chr(13) + "First line of the text at the bottom of the Image" + Chr(13) + " Second of the text at the bottom of the image"
myDoc.InlineShapes.AddPicture "C:\PrintScreen.png"
myDoc.Range.InsertBefore "First line of the text at the top of the Image" + chr(13) + "Second line of the text at the top of the Image" + Chr(13)
myMail.To = "someone@someone.com"
myMail.Subject = "This Mail is from QTP. "
myMail.Send
End If
Set myMail = Nothing
Set objOutlookMail = Nothing
Set myDoc = Nothing
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What contains Data Driven Framework document in qtp?
Which scripting language used by quicktest professional?
How to create runtime property for an object?
X flies from Hyd to bangalore using different methods of transportation. write the test scenarios and test cases for this?
How many types of parameters are available in quicktest professional (qtp)?
diff between qtp versions from 8.5
If I change the property value at runtime is it effect is object repository?
What are the types of object repository in qtp?
How the smart identification is used in real time?Please explain with an example
1. wat are the main diff b/w QTP 8.0 AND QTP 9.2 ( not user interface) 2. wat is the meaning of Keyword in keyword driven frame work? 3. how u will handle the unknown errors while exucution. (not recovery scenario)
What is text/text area checkpoint?
How can we conduct U-I Testing by using QTP??????
What are private functions in QTP? How they can be called from the function library?
what r the main attributes of test automation?
What is the file extension of the code file and object repository file in QTP?