• Vengatesh Pandiyan 7
  • NEWBIE
  • 0 Points
  • Member since 2021

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 5
    Replies
how to close the child component  that rendered from the loop . Each child components having the close button. when a user click it it has to be closed .. not all (only the child component where the click was made)
i want to upload a file from salesforce to google drive and the link of that file should be availiable under that record not only me many peoples are loooking for the same but not able to find a solution for this   if anypne implemented this already please share the code
i want to upload a file from salesforce to google drive and the link of that file should be availiable under that record not only me many peoples are loooking for the same but not able to find a solution for this   if anypne implemented this already please share the code
I am able to create a file in Google drive with the below code:

Http http = new Http();
HttpRequest req = new HttpRequest();
req.setMethod('POST');
req.setEndpoint('https://www.googleapis.com/upload/drive/v2/files?uploadType=media');
req.setHeader('content-type', 'text/plain');
req.setHeader('Authorization','Bearer '+accessToken);
String messageBody = 'Hi, This message is from Salesforce';
req.setBody(messageBody); 
req.setTimeout(60*1000);
HttpResponse resp = http.send(req);

But now i want to create a file inside a folder in Google drive. I am using end point as:

req.setEndpoint('https://www.googleapis.com/upload/drive/v2/files/0B602YDdndVQ6b3RnR2NYQXo5TXM/children?uploadType=media');
where 0B602YDdndVQ6b3RnR2NYQXo5TXM is the folder id.

Can someone please tell me what other changes i have to do in the above code in order to create the file inside a folder?

Hi all,

 

Any ane done the integration of salesforce and google.I want to upload files from salsforce to google drive using apex code.

Please help.

 

Thanks