Home
TeamSite
Drag & drop from filesite
shahbm
Hi There,
we have a requirement to drag and drop a document from filesite/desksite into our application (textbox) and store the information from that document into our database...
with Desksite, there is no issue, we can drag a dms document and we get the .nrl file with all the relevant information.
But with Filesite, we do not get any information/nrl file when we drop a dms document into our app textbox..
Could u pls let us know which control should we use to drag & drop filesite document to get (database, docid, version, description and type) of the document.
Regards,
Bhavin
Find more posts tagged with
Comments
Arwin
Do you have any control over the textbox? Is it your application/code or third party?
If I write a simple test application that has one textbox with 'AllowDrop' set to true, then the DragEnter tells me that I can accept Copy, Move or Link commands. If I then in the DragOver specify I like to receive a Link, I get a proper drag / drop Data object with all sorts of formats, including what you need (I would recommend the UnicodeText to be future proof):
Copy, Move, LinkFormat: RenPrivateSourceFolder
Data: System.IO.MemoryStream
Format: RenPrivateLatestMessages
Data: System.IO.MemoryStream
Format: RenPrivateMessages
Data: System.IO.MemoryStream
Format: RenPrivateItem
Format: FileGroupDescriptor
Data: System.IO.MemoryStream
Format: FileGroupDescriptorW
Data: System.IO.MemoryStream
Format: FileDrop
Format: FileNameW
Format: FileName
Format: FileContents
Format: Object Descriptor
Data: System.IO.MemoryStream
Format: System.String
Data: Description Number Version Class Author Edit Time
New Text Document 4,484 1 DOC AVANARUM 3/17/2011
Format: UnicodeText
Data: Description Number Version Class Author Edit Time
New Text Document 4,484 1 DOC AVANARUM 3/17/2011
Format: Text
Data: Description Number Version Class Author Edit Time
New Text Document 4,484 1 DOC AVANARUM 3/17/2011
Format: Csv
Data: System.IO.MemoryStream
shahbm
Hi there,
Thx for the reply.
We are dropping the filesite document into our own application textbox. And AllowDrop is set to true.
We are using the following code:
CType(e.Data.GetData(DataFormats.FileDrop), Array).GetValue(0)
and it throws the followind exception
"Object reference is not set to an instance of the object"
Regards,
shahbm