Skip to main content

Converts an ADO query into an excel file and returns it to the user

Is there any documentation on how to direct the method to a specific smart object?

I have a smart object named WellnessSubmissions and I try using the select * from WellnessSubmissions and it returns an error:

"Exception has been thrown by the target of an invocation. Error with ADO Query : 'select * from WellnessSubmissions' Msg : SmartObject cWellnessSubmissions] could not be found."


@HardieK2 Try querying against the Smo system name instead.


this control working fine in Smart object testign tool popup coming tosave excel file b

but how we can use this in form i am have added button contol in form on this button click added execute smart object action 

but it is not giving file download popup in form but ssame time it is working when i am trying form smart object testing tool 

 

Please help or guide 


This rocks! To use it in a Form, have the SmartObject Execute Method output to a File Attachment control on the form. The user will have to click on the File Attachment to download the exported file.


Thanks John , already done this
Also we have extended this control to export csv and other flat file as well
added option to export data in specific row and column
Added option to export Excel file based on existing Excel Temple , Temple file will be another input parameter
Thanks for initial code and documents

Hello Sachin-Walunj,

 

I just came across your comment about extending the ADO to EXCEL service object to export to csv and other flat files.

 

Can you help out with the extending version of the service object, as I have been looking for something that can deliver Export to CSV and other formats.

 

Will be really glad if you can respond to this message, as soon as you get this message...if possible.

 

Many thanks.

 

Regards.

 

Kolade.


This is awesome! I could only get it working when connecting to SQL Server databases. Is there any special configuration to make it work with Oracle databases?

 

I'm querying a SmartObject that was created based on an Oracle View, and it keeps saying there is no List methods on the SmartObject, which is weird, because the SmartObject does have a List method.

 

Thank you!


Ok, I've just figured it out!

It's an ADO Query Syntax thing. I had to specify the name of the method manually, like this:

 

SELECT * 
FROM MSmartObjectName.ListMethodName] 
WHERE RPropertyName] = '=somevalue]' 
ORDER BY  PropertyName]


Hi Guis

 

we need keep simple ADO query and we need use SMO internal name in Query

like

 

SELECT * FROM <Smartobject Internal name> WHERE PropertyName = 'value' ORDER BY  PropertyName

 

 


Hello,

 

Is there a way i can use this for exporting data from a smartobject built from SharePoint List? If so, Please suggest me on how to achieve it.

 

Thank you!


i have created and tested the smart objects - works

if i add a control to a view/form, when i click control, execute the method

nothing happens - no dialog box comes up to save excel file

please help


Hello braddo, 

 

What you have to do is very simple.

 

1. Drag an 'Attachment Control' on the view or form, where you are calling the ADO query.

 

2. The ADO to excel SmartObject returns an output when used on a view or form. The output is going to be a file, which you then map to an Attachment Control you have made available, from (1) above.

 

In summary:

After you pass in the input parameter, which is the ADO query, navigate to the output section of the ADO SmartObject configuration and map the output from your ADO SmartObject to an 'Attachment Control'.

 

Good luck braddo.


@kolade NAILED IT!

 

cheers


We are using the Excel Export SO with ADO Query. but while retrieving the data getting the error”Unable to determine the identity of domain”, we susppect the Number of Rows has limit and file size.

May I know what is the max row and max file size ADO query can be inserted into the excel?


Reply