Hi,
I have converted the datatable to html string using linq quary and i need to paste it in a file as tables with type into or set text activity but its writing as a query. can you please help how can i write it as tables
Hi,
I have converted the datatable to html string using linq quary and i need to paste it in a file as tables with type into or set text activity but its writing as a query. can you please help how can i write it as tables
Fine
Pass that html string to SET TO CLIPBOARD activity and use a SEND HOT KEY activity with key as Ctrl+v and indicate the place where u want to paste it
This will work like copy paste
Cheers @nanda_kishore
Thanx for the reply please check the screenshot. While using that its writing the data in above format but i need it in as table format. When we use the html string in smtp by checking the icon IsBodyhtml we get it as table
You can directly write the datatable to Word file using Insert Datatable in Document activity in Word activities
Install the word activities so that above can be achieveable
For Email you need to Enable the IsHtml Property
Thanks,
Srini
Yeah you will get it as a table with the mail when a html code is passed to a SMTP activity enabled with ISHTML
Which means u can see the table along the mail
@nanda_kishore
Hi @nanda_kishore ,
Could you let us know where do you want to paste the Datatable ? Is it in a Text file or Excel or Word ?
Do note that when Pasting it in the Text file, it might not be the format as you required.
Do provide us with a Sample of how the Datatable data should appear in the text file, then we could suggest the appropriate methods to achieve it.
Also, I don’t think we would require to convert it into a HTML Table if the purpose is to only print it to a Text file.
Hi Srini
It’s not an word document. My Organisation will use own email system and we need to send the data to clients using custom templates. So i need to paste the data as table in the template.
Hi Palani,
My Organisation use the own email system and we use default templates to send emails So we can’t use the email activities here. Can you suggest any other method.
Hi,
I need to paste datatable data to email body in between the two parahs. But my company use own Email system, So i can’t use the email activities here and output need to print as the screenshot.
Thanks
try the below approach
i would suggest keep it as last option if you don’t exact solution
Limitations if there are any comma in the cell values it will lead to different structures
and length of all values are not same or having null values will also lead to different structures
Regards
one more work around
try this and check
if you are getting datatable from excel and using modern activities then this will have better result
1.Use excel file and give the filepath
2.use copy/paste range , source give the range of sheet and destination give copy to clip board
3.try to give it var type text and write to text file ,if it has any problem not data is not in table format then try using ui activity opening the text file and using send key ctrl+v
Hope this helps