This is a migrated thread and some comments may be shown as answers.

Drag file in sharepoint

4 Answers 67 Views
DragAndDrop
This is a migrated thread and some comments may be shown as answers.
P
Top achievements
Rank 1
P asked on 22 Aug 2011, 09:29 PM
Hello,
I am using the RadUploadDropPanel and bound it to RadUpload to upload files on the server. This is part of silverlight application. 

If i use classic C# web application to host the silverlight app, the drag works fine.

But when i add the silverlight web part in sharepoint 2010, i am no longer able to drag'n drop file. Instead of drop the browser actually opens the file. Also, i have added AllowDrop = true for both the drag panel as well as raduplod controls.

Any help would be greatly appreciated.

thanks,

4 Answers, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 25 Aug 2011, 05:08 PM
Hi P,

We are not aware of such issues with the RadUpload and RadUploadDropPanel controls in Windows. I attached a sample project that works as expected on our side. However, please keep in mind that this solution is testes in Win2008R2 server and there are known limitations to dropping files in the RadUpload controls under Mac and Safari.

Best wishes,
Tina Stancheva
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

0
P
Top achievements
Rank 1
answered on 25 Aug 2011, 09:20 PM
Tina,
see my comments below.
0
P
Top achievements
Rank 1
answered on 26 Aug 2011, 04:14 PM
Tina,
After my reply i suspected that i would be how we are adding web part to the sharepoint, and i was right. 

If you add the XAP as silverlight webpart, it doesn't work.

If you add it as a custom webpart, it works fine. 

Since, we are using Client Object Model, we have to use Silverlight WebPart in SharePoint. Can you help to get this working with silverlight webpart as well.

thanks,
0
Tina Stancheva
Telerik team
answered on 31 Aug 2011, 01:23 PM
Hi P,

This issue is caused by the default Windoless mode of the SL WebPart. Basically when you add the XAP as silverlight webpart by default the SL plug-in is in Windowless mode:
<object id="SilverlightObjectTag_WebPartctl00_m_g_7e5626f6_2a6f_4bfb_bbdb_f9bcaae030f0" data="data:application/x-silverlight-2," type="application/x-silverlight-2" style="display:block" height="700px" width="100%" class="ms-dlgDisable">
    <param name="source" value="/XAPs1/383164_UploadExample.xap"/>
    <param name="onerror" value="_spOnSilverlightError_WebPartctl00_m_g_7e5626f6_2a6f_4bfb_bbdb_f9bcaae030f0" />
    <param name="background" value="white" />
    <param name="initParams" value="MS.SP.url=http%3A%2F%2Flocalhost,MS.SP.formDigest=0xBEF354F52076E9CC587E547C0BD878210F1FE50E0C378B2F9B941E13CAD0C5ED9932E9EC32D2CBC8BBB5D88499CACFCE1A5FB3CF7A6571736B456B6003D32CA8%2C31%20Aug%202011%2011%3A52%3A14%20%2D0000,MS.SP.formDigestTimeoutSeconds=1800,%3Cproperty%20name=%22WindowlessMode%22%20type%3D%22bool%22%3Efalse%3C%2Fproperty%3E" />
    <param name="windowless" value="true" />
    <a href="http://go.microsoft.com/fwlink/?LinkID=149156&v=3.0.40624.0" style="text-decoration: none;">
        <img src="http://go.microsoft.com/fwlink/?LinkId=108181" alt="Get Microsoft Silverlight" style="border-style: none"/>
    </a>    
</object>
However, when in windowless mode the drag/drop functionality doesn't work so you need to edit the WebPart definition to set the windowless mode to false (read more).


Regards,
Tina Stancheva
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

Tags
DragAndDrop
Asked by
P
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
P
Top achievements
Rank 1
Share this question
or