Skip to main content
edited body; edited title
Source Link

Query the fields of an attribute table of a .shp file (ArcMap) from an .xlsmxlsx file with Python

What I want to do is query the fields of a .shp file from an Excel .xlsmxlsx file, that is, avoid the repetitive and manual process of copying the attribute table from ArcMap to the working .xlsmxlsx file,

For example, query and write the values ​​of this attribute table displayed in arcmap and contained in the VHDissolve.shp file from my Excel VINCULACION.xlsmxlsx file

enter image description here enter image description here

Note: The attribute table and the table in Excel have the same fields.

This is a good start apparently

# Set local variables

inTable = outTable

outXLS = VHFolder + "/Vinculacion_S.xlsx" #this is where I had to give the file path and then the file name

# Execute TableToExcel

arcpy.TableToExcel_conversion(inTable, outXLS)

ersion(inTable, outXLS)

Annex link with the .shp and .xlsm files https://drive.google.com/file/d/1z7tbOCxQ0Xjl24tCCmfKMpcgnuomdHT-/view?usp=sharing

Query the fields of an attribute table of a .shp file (ArcMap) from an .xlsm file with Python

What I want to do is query the fields of a .shp file from an Excel .xlsm file, that is, avoid the repetitive and manual process of copying the attribute table from ArcMap to the working .xlsm file,

For example, query and write the values ​​of this attribute table displayed in arcmap and contained in the VHDissolve.shp file from my Excel VINCULACION.xlsm file

enter image description here enter image description here

Note: The attribute table and the table in Excel have the same fields.

This is a good start apparently

# Set local variables

inTable = outTable

outXLS = VHFolder + "/Vinculacion_S.xlsx" #this is where I had to give the file path and then the file name

# Execute TableToExcel

arcpy.TableToExcel_conversion(inTable, outXLS)

ersion(inTable, outXLS)

Annex link with the .shp and .xlsm files https://drive.google.com/file/d/1z7tbOCxQ0Xjl24tCCmfKMpcgnuomdHT-/view?usp=sharing

Query the fields of an attribute table of a .shp file (ArcMap) from an .xlsx file with Python

What I want to do is query the fields of a .shp file from an Excel .xlsx file, that is, avoid the repetitive and manual process of copying the attribute table from ArcMap to the working .xlsx file,

For example, query and write the values ​​of this attribute table displayed in arcmap and contained in the VHDissolve.shp file from my Excel VINCULACION.xlsx file

enter image description here enter image description here

Note: The attribute table and the table in Excel have the same fields.

This is a good start apparently

# Set local variables

inTable = outTable

outXLS = VHFolder + "/Vinculacion_S.xlsx" #this is where I had to give the file path and then the file name

# Execute TableToExcel

arcpy.TableToExcel_conversion(inTable, outXLS)

ersion(inTable, outXLS)

Annex link with the .shp and .xlsm files https://drive.google.com/file/d/1z7tbOCxQ0Xjl24tCCmfKMpcgnuomdHT-/view?usp=sharing

Post Closed as "Not suitable for this site" by Vince, TomazicM, Cyril Mikhalchenko, If you do not know- just GIS, jcarlson
edited tags
Link
PolyGeo
  • 65.4k
  • 29
  • 114
  • 345
edited tags
Link
PolyGeo
  • 65.4k
  • 29
  • 114
  • 345
deleted 2 characters in body
Source Link
Loading
edited body
Source Link
Loading
naming
Source Link
Vince
  • 20.3k
  • 16
  • 48
  • 65
Loading
added 466 characters in body
Source Link
Loading
deleted 26 characters in body
Source Link
Loading
naming; removed appreciation and closing
Source Link
Vince
  • 20.3k
  • 16
  • 48
  • 65
Loading
Source Link
Loading