지원 중단되었습니다. 대신 People API 고급 서비스를 사용하세요.
연락처의 날짜 필드.
이 클래스는 연락처 서비스에서만 사용되며 App Script의 다른 곳에서 사용되는 날짜는 자바스크립트의 표준 날짜 객체를 사용합니다.
방법
메서드 | 반환 유형 | 간략한 설명 |
---|---|---|
getLabel() | Object | 이 필드의 라벨을 가져옵니다. |
setLabel(label) |
| 이 필드의 라벨을 설정합니다. |
자세한 문서
getLabel()
이 필드의 라벨을 가져옵니다. 필드, ExtendedField 또는 문자열일 수 있습니다.
// Logs the label for all the address fields associated with contact // 'John Doe'. This method can be similarly called for any field that has // a label. var contacts = ContactsApp.getContactsByName('John Doe'); var addressFields = contacts[0].getAddresses(); for (var i = 0; i < addressFields.length; i++) { Logger.log(addressFields[i].getLabel()); }
리턴
Object
: 이 필드의 라벨
승인
이 방법을 사용하는 스크립트는 다음 범위 중 하나 이상을 승인해야 합니다.
-
https://www.google.com/m8/feeds
setLabel(label)
이 필드의 라벨을 설정합니다.
// Sets the label to 'Apartment' for the first address field associated // with contact 'John Doe'. This method can be similarly called for any // field that has a label. var contacts = ContactsApp.getContactsByName('John Doe'); var addressFields = contacts[0].getAddresses(); addressFields[0].setLabel('Apartment');
매개변수
이름 | 유형 | 설명 |
---|---|---|
label | String | 이 필드의 새 라벨 |
리턴
: 이 필드로, 연결하는 데 유용합니다.DateField
승인
이 방법을 사용하는 스크립트는 다음 범위 중 하나 이상을 승인해야 합니다.
-
https://www.google.com/m8/feeds