Skip to main content

Hi! Dear,


Would you please let me know is there anyway to have result record as (text)variables in Javascript ?


Image as:


//////////////////////////////////////////////////////////


function getData(){


base(‘New Playlists’).select({

filterByFormula: ‘ID = MyFunIDValue’,

}).eachPage(function page(records, fetchNextPage) {

records.forEach(function(record) {

return record.get(‘ID’);

});


}, function done(error) {


});


}


var data = getData();


alert(data);


//////////////////////////////////////////////////////////


in this way I could have only result “undefined”…


I thought it is trouble with asymetric treatment.


but it didn’t work well


like this…


$.when(

getData()

).done(function(){

alert(result);

});


Please tell me what should be fixed or is there another command smart,


like just


getData(table,field,formula)

Be the first to reply!

Reply