GESI MemberID


(Mellanie Donier) #1

Does someone know the Line to get the Corporation Member IDS to names ?

=HLOOKUP(“name”; universe_types_type(“en-us”; INDIRECT(ADDRESS(ROW(); 12)); TRUE); 2; FALSE)

does not work.

Help would be nice, thanks


(Blacksmoke16) #2

Is there an error or? It might be due to ESI being down/wonky due to the DDoS attack.


(Mellanie Donier) #3

Error #REFF “Out of bound Range” and no its not because of the DDoS attack.
And the command i posted did convert : type_id to name . i am now looking for the GESI Command to convert Member_ID to name .

Thanks for your reply


(Blacksmoke16) #4

Could use a custom function like

function corpMembers(name) {
  var member_ids = corporations_corporation_members(name,false);
  var members = [];
  
  eachSlice_(member_ids, 100).forEach(function(m) {
    members = members.concat(characters_names(m.join(','),false));
  });
  
  return members
}

Then use it like =corpMembers()


(Mellanie Donier) #5

added your code to the function.gs at the bottom.

getting this error now :

Error
ReferenceError: “eachSlice_” is not defined. (line 2039).

Did i miss something?

--------EDIT 2------
is it also not possible to add a funtion to endpoints.gs to get name and not the id ?

Thanks


(Blacksmoke16) #6

OO my bad, there was another function required for this:

function eachSlice_(array, size){
  var arr = []
  for (var i = 0, l = array.length; i < l; i += size){
    arr.push(array.slice(i, i + size))
  }
  return arr
};

No, ESI corp member list endpoint only returns IDs of the characters.


(Mellanie Donier) #7

Yes. It shows ids and names now. Can i marry you :slight_smile:

Thank you

P.S. Would be good if you add those two functions to funtion.gs for all to have :stuck_out_tongue:


(Blacksmoke16) #8

No, GESI is just a method of getting data from ESI into Sheets. What the user’s do with it is up to them. I don’t want it to become something that has a bunch of user specific features.

I could maybe make another file that would be optional that i could put common things tho…I’ll have to think about it.


(Mellanie Donier) #9

Please think anout it and Thanks again :slight_smile:
Good Hunting and Good Weekend


(system) #10

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.