Skip to main content
replaced http://gis.stackexchange.com/ with https://gis.stackexchange.com/
Source Link

It should be possible to cast your featurelayer to ITableFields, then loop through each ITableField.FieldInfo and set IFieldInfo.Alias. Last time I checked no error was raised when I assigned more than one field the same alias, so be careful.

Update: Field aliases can be confusing. There's an alias for fields that are stored in the database (IField.AliasName) which can be changed as shown in this threadas shown in this thread. The IFieldInfo.Aliases are what you change when you go into the Fields tab on the Layer Properties dialog in ArcMap. I think those get initialized to whatever the IField.Alias is.

It should be possible to cast your featurelayer to ITableFields, then loop through each ITableField.FieldInfo and set IFieldInfo.Alias. Last time I checked no error was raised when I assigned more than one field the same alias, so be careful.

Update: Field aliases can be confusing. There's an alias for fields that are stored in the database (IField.AliasName) which can be changed as shown in this thread. The IFieldInfo.Aliases are what you change when you go into the Fields tab on the Layer Properties dialog in ArcMap. I think those get initialized to whatever the IField.Alias is.

It should be possible to cast your featurelayer to ITableFields, then loop through each ITableField.FieldInfo and set IFieldInfo.Alias. Last time I checked no error was raised when I assigned more than one field the same alias, so be careful.

Update: Field aliases can be confusing. There's an alias for fields that are stored in the database (IField.AliasName) which can be changed as shown in this thread. The IFieldInfo.Aliases are what you change when you go into the Fields tab on the Layer Properties dialog in ArcMap. I think those get initialized to whatever the IField.Alias is.

added 601 characters in body
Source Link
Kirk Kuykendall
  • 25.8k
  • 8
  • 67
  • 155

It should be possible to cast your featurelayer to ITableFields, then loop through each ITableField.FieldInfo and set IFieldInfo.Alias. Last time I checked no error was raised when I assigned more than one field the same alias, so be careful.

Update: Field aliases can be confusing. There's an alias for fields that are stored in the database (IField.AliasName) which can be changed as shown in this thread. The IFieldInfo.Aliases are what you change when you go into the Fields tab on the Layer Properties dialog in ArcMap. I think those get initialized to whatever the IField.Alias is.

It should be possible to cast your featurelayer to ITableFields, then loop through each ITableField.FieldInfo and set IFieldInfo.Alias. Last time I checked no error was raised when I assigned more than one field the same alias, so be careful.

It should be possible to cast your featurelayer to ITableFields, then loop through each ITableField.FieldInfo and set IFieldInfo.Alias. Last time I checked no error was raised when I assigned more than one field the same alias, so be careful.

Update: Field aliases can be confusing. There's an alias for fields that are stored in the database (IField.AliasName) which can be changed as shown in this thread. The IFieldInfo.Aliases are what you change when you go into the Fields tab on the Layer Properties dialog in ArcMap. I think those get initialized to whatever the IField.Alias is.

Source Link
Kirk Kuykendall
  • 25.8k
  • 8
  • 67
  • 155

It should be possible to cast your featurelayer to ITableFields, then loop through each ITableField.FieldInfo and set IFieldInfo.Alias. Last time I checked no error was raised when I assigned more than one field the same alias, so be careful.