Skip to main content

Questions tagged [bat]

File extension for Microsoft batch files

Filter by
Sorted by
Tagged with
0 votes
0 answers
66 views

Launch QGIS using a batch file

I am very new to QGIS and Python 3. I have QGIS 3.32.1 installed and Python 11. I do not have the OSGEO4W version. My QGIS sits in the Program files directory (C:\Program Files\QGIS 3.32.1). This is ...
Lora's user avatar
  • 1
2 votes
0 answers
229 views

Polygonize tool error "Process gdal_polygonize.bat failed to start"

I am trying to use the Polygonize (Raster to Vector) tool on QGIS-LTR on Windows 11. When I launch the tool on a layer I get the following error. Input parameters: { 'BAND' : 1, 'EIGHT_CONNECTEDNESS' :...
Elia's user avatar
  • 21
1 vote
0 answers
86 views

Executing PyQGIS scripts from .bat file to control open instance of QGIS

I'm trying to run PyQGIS scripts via a 3rd party program, to perform actions to layers inside an open QGIS instance. I'm able to have the outside program shell and execute a bat file to run them. I'm ...
Kaizen777's user avatar
0 votes
1 answer
423 views

Access ArcGIS Python environment, installed via in Anaconda Navigator, from .bat script in normal cmd window?

I'm trying to run a Python script (shapefile_upload.py) which uses ArcGIS libraries. I installed the ArcGIS libraries by following exactly these instructions. The Python script uploads a shapefile to ...
Nena's user avatar
  • 141
-1 votes
1 answer
127 views

How to add US State NHGIS historical GIS data to PostGIS? ERROR: INSERT has more target columns than expressions

I am trying to add historical data extracted from NHGIS to PostGIS, but I get the INSERT has more target columns than expressions error when I run the code below: "C:\psql.exe" -c "...
iDevPy's user avatar
  • 99
1 vote
0 answers
95 views

Creating/Deleting fields (with expression) for a shapefile in a batch script

I am new to GDAL/Scripting in general. For a study project, I have to create two new fields to a shapefile/vector file using a certain expression. I also need to delete two fields. Normally, I would ...
Nokturius's user avatar
  • 119
2 votes
1 answer
316 views

Starting QGIS processing algorithms from .bat-file [closed]

I have written multiple Python scripts within the QGIS 2.18 processing framework to process a sequence of tasks. What I am trying to achieve now is to call the python scripts from a .bat-file without ...
applebrown's user avatar
0 votes
1 answer
3k views

QGIS Python SyntaxError file=sys.stderr) File "C:\OSGeo4W64\apps\Python37\lib\site.py", line 177

I am executing a .py file from a windows .bat file for doing a QGIS Desktop 3.8.3 geoprocessing task. I am using the following .bat file : @echo off call C:\OSGeo4W64\bin\o4w_env.bat REM Change ...
Sreeraj's user avatar
  • 729
0 votes
1 answer
257 views

Launch bat. for QGIS 3 python not working

I'm trying to build a launch.bat for qgis 3 python. I would want to run python via batch file but I get an error 'no module named processing' Launch.bat: @ECHO OFF set OSGEO4W_ROOT=C:\OSGeo4W64 @...
woundari's user avatar
  • 131
3 votes
2 answers
834 views

Launch QGIS GUI using batch file and Python 3 - Windows 10

Ultimately I'm attempting to launch the QGIS GUI and run a python script from a batch file. I've reviewed numerous instances referencing similar scenarios on this and other forums but for the life of ...
kiwibyron's user avatar
4 votes
1 answer
3k views

Creating a .bat file to run multiple FME scripts

I have the task of creating a batch file that will run FME scripts that update data layers to AGOL. I am completely unfamiliar with .bat and have not found anything online that really summarizes the ...
Jeff's user avatar
  • 79
2 votes
2 answers
2k views

Using Windows Batch File (.bat) for executing QGIS Python program without opening QGIS Software

I have a Python Program for doing some geoprocessing in QGIS. The starting of the Python program is given below. import sys from qgis.core import * import qgis.utils from qgis.gui import * from ...
Sreeraj's user avatar
  • 729
2 votes
1 answer
1k views

Writing a Batch File (.bat) Script to run a QGIS Python Script without opening QGIS [closed]

I have saved a python script (named as 'Task3.py'). Currently, I will open QGIS and then run this Task3.py . This python script is saved in C:\Users\Sreeraj.qgis2\processing\scripts\Task3.py . But, I ...
Sreeraj's user avatar
  • 729
2 votes
1 answer
1k views

Installing pip packages from bat file and OSGEO Shell?

After installing QGIS (that from the 2.14 version has pip installed by default) I want to automatically install some pip packages within a bat file. One method to do that is writing a file.txt with ...
matteo's user avatar
  • 3,304
7 votes
2 answers
5k views

How to change default path for ".qgis2" folder on Windows?

I'm working with Windows 8 32Bit OS and QGIS 2.8.2. The QGIS default installing path for ".qgis2" folder is C:\Users\image95\\.qgis2. This directory stores several useful components like QGIS ...
user35117's user avatar
  • 939
9 votes
1 answer
809 views

Calling Python through BAT for Scheduled Task

I'm using ArcGIS 10.1 and setting up some scheduled tasks to run on our server. I am calling a python script in a .bat file. When it runs, the connection to our SDE database is "invalid" or do not ...
GISHuman's user avatar
  • 3,691
1 vote
2 answers
2k views

Start postgresql+postgis without installation on Windows

I have used Windows7x64 and want start PostgreSQL+POSTGIS without installation process. I copy PostgresSQl\9.1 folder from other laptop to c:\opt. I need create .bat file with enviroment variables and ...
Andrey Maraev's user avatar
4 votes
1 answer
833 views

How to echo gdal process to screen and pipe to text file in Windows?

gdal_warp and similar give a nice progress summary when run and I want this output to show in the osgeo shell and also pipe to a text file. The issue is when I add the pipe the output doesn't show on ...
GeorgeC's user avatar
  • 8,238