We help IT Professionals succeed at work.

Using DDE in VB6

turnerrob
turnerrob asked
on
I have bought a program  Snagit, which captures an image from a web page , and converts an area selected to text, and saves to a file.

The program has DDE capability.

I have never used DDE!!!!
---
From documentation...

To initiate DDE Session..

[DDE_INITIATE command] Snagit System

???How is this started in VB6

----
CAPTURE SCREEN TO TIF FILE
---------------------------

[DDE_EXECUTE command] eSNAG (SCR,TIF SCRSHOT1.TIF,COL,DEF,9)

My Question is...
How do i invoke these commands $##$#$@#

Would appreciate some advice..



Comment
Watch Question

Head of Software Services
CERTIFIED EXPERT
Commented:
turnerrob:

Here is a sample which will capture the screen using snagit and save it to a file. (The default location for this is the snagit installation folder).

Private Sub Command1_Click()
    With Text1
        .LinkTopic = "SnagIt|System"
        .LinkItem = "Status"
        .LinkMode = vbLinkManual
        .LinkRequest
        .LinkExecute "Esnag (SCR, TIF SCRSHOT1.TIF, COL, DEF, 9)"
    End With
End Sub

All it requires is a text box (Text1) on a form and a command button to execute it!

Obviously SnagIt must be running when you execute the DDE command otherwise you will get an error 285. You can start snagit using the Shell function e.g.,

Shell("c:\Program Files\Techsmith\snagit\snagit32.exe",vbHide)

Author

Commented:
TimCottee.
Thanks very much for your advice, much appreciated.
It would appear from your comments, you have used Snagit.
The actual application of snagit i need to use is much more complicated than above. I will see how i go!!!!!!

Regards   Turnerrob
TimCotteeHead of Software Services
CERTIFIED EXPERT

Commented:
I have used it once or twice, only as an evaluation though so I haven't really used it in anger. Fortunately I still had it installed so could test this reasonably easily.

Author

Commented:
Thanks for your help, i will proceed and attack!! it.
The documentation with the package is pretty good, and should be able to get a result.
I was looking for the easy !!  way out.

Regards   Turnerrob

Explore More ContentExplore courses, solutions, and other research materials related to this topic.