ole drag and drop (IE url) 
Author Message
 ole drag and drop (IE url)

I  have a form that accepts drag and drop and it works perfectly fine aside
from URLs that come from IE.
I read in some places that I need to do something about OLE drag and drop,
but it wasnt clear what I need to do, someone suggested doing this:
System.Threading.Thread.CurrentThread.ApartmentState =
System.Threading.ApartmentState.STA;

But it didnt fix my problem.

Any suggestions?

Thanks,

--Carlos



Sat, 30 Apr 2005 05:34:56 GMT  
 ole drag and drop (IE url)
Coming from IE, its a different clipboard format. So, you have to register
the clipboard format.

Dim CF_HTML as Long
       CF_HTML = RegisterClipboardFormat("HTML Format")

Right now, I'm installing .Net, so I can't immediately get into it to do the
exact systax.  So, humor me if its a bit off:

 [DllImport("user32.dll")]
    static extern int RegisterClipboardFormat(string lpString);

Anyway, hope this helps.


Quote:
> I  have a form that accepts drag and drop and it works perfectly fine
aside
> from URLs that come from IE.
> I read in some places that I need to do something about OLE drag and drop,
> but it wasnt clear what I need to do, someone suggested doing this:
> System.Threading.Thread.CurrentThread.ApartmentState =
> System.Threading.ApartmentState.STA;

> But it didnt fix my problem.

> Any suggestions?

> Thanks,

> --Carlos



Sat, 30 Apr 2005 08:40:57 GMT  
 ole drag and drop (IE url)
your explanation makes sense but how would I go about implementing that on
.NET?

--Carlos



Quote:
> Coming from IE, its a different clipboard format. So, you have to register
> the clipboard format.

> Dim CF_HTML as Long
>        CF_HTML = RegisterClipboardFormat("HTML Format")

> Right now, I'm installing .Net, so I can't immediately get into it to do
the
> exact systax.  So, humor me if its a bit off:

>  [DllImport("user32.dll")]
>     static extern int RegisterClipboardFormat(string lpString);

> Anyway, hope this helps.



> > I  have a form that accepts drag and drop and it works perfectly fine
> aside
> > from URLs that come from IE.
> > I read in some places that I need to do something about OLE drag and
drop,
> > but it wasnt clear what I need to do, someone suggested doing this:
> > System.Threading.Thread.CurrentThread.ApartmentState =
> > System.Threading.ApartmentState.STA;

> > But it didnt fix my problem.

> > Any suggestions?

> > Thanks,

> > --Carlos



Sat, 30 Apr 2005 13:47:12 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Accept link(URL)-drop(by drag) from IE?

2. OLE drag & drop (drag image)

3. IE shortcut drag and drop...

4. Drag-and-drop is OK, but IE wants to launch my app anew each time

5. How do you do Ole drag and drop in WTL

6. Ole Drag&Drop problem

7. ATL dll ole drag and drop

8. OLE Drag and Drop in ATL/WTL

9. OLE Drag&Drop from Outlook

10. OLE drag and drop.

11. OLE Drag and Drop

12. drag and drop without OLE?

 

 
Powered by phpBB® Forum Software