|
-
Dec 13th, 2004, 02:45 PM
#1
Thread Starter
Fanatic Member
Animated Gifs Into OutlookExpress (PLEASE HELP)
This is what i want to do....
I am using the webbrowser control to display animated gifs in my own VB form.
When I click on an animated gif image I want to copy that animated image into Outlook Express (using the Html format).
How can I copy an animated gif image to the clipboard and then paste it into Outlook Express from within a web browser control?
Thanks
Last edited by epixelman; Dec 14th, 2004 at 09:20 PM.
-
Dec 13th, 2004, 08:38 PM
#2
Thread Starter
Fanatic Member
Re: Insert Animated Gifs Into OutLookExpress
Anyone ever used SmileyCentrals.com's smiley's??
They do the same thing I am looking for. When you click on a smiley animated gif. It copy's and pastes the picture into OutLookExpress at the current cursor position.
I am thinking that it is using sendkeys or sendmessage to do this. I am thinking that it is using javascript or something in the "onClick" event of the image to run the vb code or to some DLL or something.
But I can't see the html code to verify this
Any help please!
-
Dec 14th, 2004, 06:57 AM
#3
Thread Starter
Fanatic Member
Re: Insert Animated Gifs Into OutlookExpress
Surely someone has tried this?
Any help please?
-
Dec 14th, 2004, 10:01 AM
#4
Thread Starter
Fanatic Member
Re: Insert Animated Gifs Into OutlookExpress
tap, tap, tap, tap (with my fingers)
Can anyone help me?
-
Dec 14th, 2004, 02:13 PM
#5
Thread Starter
Fanatic Member
Re: Insert Animated Gifs Into OutlookExpress
Anyone know of a javascript command that can run a VB command??
This could allow me to put a javascript command in the "click" event of the animated gif on the html page.
PLEASE HELP!!!
I DROWNING IN BINARY CODE HEADACHES!
-
Dec 14th, 2004, 05:44 PM
#6
Thread Starter
Fanatic Member
Re: Insert Animated Gifs Into OutlookExpress
Come on....
You mean there are no smart VB programmers out there??
-
Dec 14th, 2004, 09:21 PM
#7
Thread Starter
Fanatic Member
Re: Animated Gifs Into OutlookExpress (PLEASE HELP)
Boy... I guess there are no good programmers here?
-
Dec 14th, 2004, 09:33 PM
#8
Re: Animated Gifs Into OutlookExpress (PLEASE HELP)
must be a problem that is not worthy of the efforts of a "good programmer"
-
Dec 15th, 2004, 07:09 AM
#9
Thread Starter
Fanatic Member
Re: Animated Gifs Into OutlookExpress (PLEASE HELP)
No....
I think that this may to hard for most programmers because I am trying to run a VB command through a web link on the browser control.
I guess I have a dilema!
So lets try this!
How do you copy and paste an animated gif (by clicking on it) just using VB commands from within my VB form, no browser control??
I have tried using the gif89a.dll but I can not find a way to copy the gif to the clipboard. Theres no properties in the dll for this.
Any ideas on this??
-
Dec 15th, 2004, 06:05 PM
#10
Thread Starter
Fanatic Member
Re: Animated Gifs Into OutlookExpress (PLEASE HELP)
Come on....
Will somebody help me?
-
Dec 15th, 2004, 06:28 PM
#11
Re: Animated Gifs Into OutlookExpress (PLEASE HELP)
I would think it would involve having the Path to your gif available in your code.
As to the "Clicking", it would be an event fired in the box, frame, form, whatever control you have your gif presented in.
Using the Clipboard to Copy, I believe you'd use the SetData method:
SetData Method
Puts a picture on the Clipboard object using the specified graphic format. Doesn't support named arguments.
Syntax
object.SetData data, format
The SetData method syntax has these parts:
PartDescriptionobjectRequired. An object expression that evaluates to an object in the Applies To list. dataRequired. A graphic to be placed on the Clipboard object. format Optional. A constant or value that specifies one of the Clipboard object formats recognized by Visual Basic, as described in Settings. If format is omitted, SetData automatically determines the graphic format.
Settings
The settings for format are:
ConstantValueDescriptionvbCFBitmap2 Bitmap (.bmp files) vbCFMetafile3 Metafile (.wmf files) vbCFDIB8Device-independent bitmap (DIB) vbCFPalette9Color palette
Remarks
These constants are listed in the Visual Basic (VB) object library in the Object Browser.
You set the graphic that is to be placed onto the Clipboard object with either the LoadPicture function or the Picture property of a Form, Image, or PictureBox.
As to the Pasting, Then I'd guess you'd use the GetData Method:
GetData Method
Returns a graphic from the Clipboard object. Doesn't supportnamed arguments.
Syntax
object.GetData (format)
The GetData method syntax has these parts:
PartDescriptionobjectRequired. Anobject expression that evaluates to an object in the Applies To list.format Optional. A constant or value that specifies the Clipboard graphics format, as described in Settings. Parentheses must enclose the constant or value. If format is 0 or omitted, GetData automatically uses the appropriate format.
Settings
The settings for format are:
ConstantValueDescriptionvbCFBitmap2Bitmap (.bmp files)vbCFMetafile3Metafile (.wmf files)vbCFDIB8Device-independent bitmap (DIB)vbCFPalette9Color palette
Remarks
These constants are listed in the Visual Basic (VB)object library in theObject Browser.
If no graphic on the Clipboard object matches the expected format, nothing is returned. If only a color palette is present on the Clipboard object, a minimum size (1 x 1) DIB is created
-
Dec 16th, 2004, 07:10 AM
#12
Thread Starter
Fanatic Member
Re: Animated Gifs Into OutlookExpress (PLEASE HELP)
WOW!! Someone replied!
Thank you!!!
But...
I already know how to do the copy and paste. The problem I am having is copying the animated gif (with all the frames) from the gif89a.dll control (or any control that can copy an anim gif).
The gif89a.dll control doesn't have a method of doing this that I can see. It has no "click" event or "picture" property.
But thanks for your reponse.
-
Dec 16th, 2004, 08:31 AM
#13
Re: Animated Gifs Into OutlookExpress (PLEASE HELP)
Hmmph.
Well, I wouldn't mind researching this a little bit.
But I don't think I have this gif89a.dll control.
Looking at my controls and referance lists, Nothing even starts with gif.
Hmmm, lets google...
hmmm, could download it here:http://www.devcity.net/forums/topic....6163&#RID47318
Ok, lets see if I understand.
You want to achieve the following:
Step 1) Click a Gif that you have displayed on a form. {Displayed VIA this Gif89a.dll}
Step 2) Detect Click, Copy all Layers of AniGif to clipboard.
Step 3) With Outlook Running, and a New Message existant, click it.
Step 4) Watch Gif appear as attachment in New Message.
Is This Correct?
Whats the difference between Step 2 and copying the file via clipboard SetData?
- If the Gif89a.dll does NOT have a click event, you might want to hook the forms messages...
Just did a quick search, here's an oldie from MartinLiss :http://www.vbforums.com/showthread.p...t=hook+message
But I'm sure you can find better threads about Message Hooking.
Hmmm, Step 3 & 4 require you to detect Clicking in Outlook.
I Know there are API functions that will tell you what your mouse is hovering over.
So, if you can then detect the Mouse Click, and if its over a window that you can percieve to be a New Outlook Message, then you can tell the Clipboard to Paste.
Or, perhaps ShellExecute can call out the "paste" command?
Havn't needed to API in a while, Sorry for being so vague.
-Lou
-
Dec 16th, 2004, 08:45 AM
#14
Thread Starter
Fanatic Member
Re: Animated Gifs Into OutlookExpress (PLEASE HELP)
Your're pretty close!!
BTW... I messed up... it's gif89.dll (no a)
Do a search for the dll, it simply loads as an OCX component would (after registering it of course)
Anyways....
Yes, I want to click on the gif89.dll control on my form and copy the entire animated gif (all frames) to the clipboard. Pasting it is not my problem at this time. I want to paste the gif in the message area, not as an attachment.
Actaully copying the entire gif from the gif control is the problem. There is no click event or a picture property.
I am trying to make a program simular to "Smiley/Emoticons" type program, but I can use any picture... i.e. animated gifs, jpeg, gif etc...
FYI, I really want to use the web browser control, but I can not figure out how to run VB code through the an image on a web page in the web control.
Thanks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|