function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Rodolfo NoviskiRodolfo Noviski 

Use Google API to read Excel file

Using the code below, following the tutorial available in the salesforce site.

        xmldom.element oneSpreadSheet = feedWk.entries[0]; // expects one spreadsheet 
        // get a new feed listing the worksheets in oneSpreadSheet
        GoogleData worksheetsFeed = service.getWorksheets( oneSpreadSheet );
               
        // pick the first one to rename
        GoogleData.Worksheet ws = new GoogleData.Worksheet( worksheetsFeed.entries[0] );
       
        string cellFeedUrl = ws.getCellFeedUrl();
      
        // specify range to avoid data overflow
       GoogleData feed = service.getFeed( cellFeedUrl );
       
  list<GoogleData.Cell> cells = ws.cellFactory( feed.entries );                 
  for (GoogleData.Cell cel : cells  )
        {
            cel.dump();
            system.debug ( cel.title + ' ' + cel.content ); 
            system.debug ( cel.id + ' ' +cel.row + ' ' + cel.col + ' ' + cel.edit );
  }

I'm not able to get a response when you run this code block. More specifically this line:
// specify range to avoid data overflow
       GoogleData feed = service.getFeed( cellFeedUrl );
      
  list<GoogleData.Cell> cells = ws.cellFactory( feed.entries );                
  for (GoogleData.Cell cel : cells  )
        {
            cel.dump();
            system.debug ( cel.title + ' ' + cel.content );
            system.debug ( cel.id + ' ' +cel.row + ' ' + cel.col + ' ' + cel.edit );
  }


No returns me no message in the log, not of error but returns no value, and the spreadsheet has values ​​to be returned

Has anyone had a similar experience? Could anyone help me?
thank you