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

Sending Files

1 Answer 153 Views
Conversational UI, Chat
This is a migrated thread and some comments may be shown as answers.
Alien
Top achievements
Rank 1
Alien asked on 26 Jan 2020, 03:18 PM

hello i'm using radchat on my project and i have two questions

one

I've read how to sending a image but i'm not sure how i can send other files like Audio,video...

 

ChatMediaMessage mediaMessage = new ChatMediaMessage(img, new Size(300, 200), null, Chat_Box.Author, DateTime.Now);

 

two

and also are some of them like video types going to have a preview in the radchat like the image or not

if not how i can access the file that radchat is showing to execute it example like this Process.Start("C:\\");

thank you 

 

1 Answer, 1 is accepted

Sort by
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 27 Jan 2020, 12:15 PM
Hello, Alien,  

ChatMediaMessage is designed to display images. Currently, RadChat doesn't support sending files functionality out of the box. To be honest, this is more like a task that the developer should implement because he/she can decide where exactly to store the file you want to send and then download it from there. 

RadChat is purposed to provided the UI and the convenient API. Then, you need to implement the exact functionality that you want to have. RadChat offers a ChatToolbarElement that allows adding different toolbar actions for achieving more user friendly conversational UI. It is placed below the text box and it can be shown/hidden by clicking the toolbar icon in the editable part: https://docs.telerik.com/devtools/winforms/controls/chat/toolbar 

Thus, you can add a custom action there that provides you with UI for selecting a file and sending. After some research in general programming forums, I have found the following threads which may be suitable for sending and downloading files: https://social.technet.microsoft.com/wiki/contents/articles/38274.consume-web-api-in-winform-for-file-handling.aspx    

I hope this information helps. If you need any further assistance please don't hesitate to contact me. 

 

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik

RadChat for Winforms
Tags
Conversational UI, Chat
Asked by
Alien
Top achievements
Rank 1
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or