nwvalidate

Validate a network name

Syntax

nwvalidate 
netname

Description

Checks if a network netname already exists. In case it does, the command makes a suggestion for an alternative name. Normally, the command returns netname_1. If that also exists, the commands returns netname_2.

Network types

The command works the same for every network type (see nwnetworktypes).

Examples

. nwclear
. nwwebuse florentine
. nwvalidate flobusiness
. return list

Stored results

  • r(exists) — “true” when network name already exists, “false” otherwise
  • r(tryname) — network name that is validated
  • r(validname) — valid name in case the tryname already exists (otherwise the tryname)

nwcommands version 3.25.0, 14 November 2026 (check your installed version)


Back to top

nwcommands is free software under the GNU General Public License, version 3, as are the model packages nwsaom, nwergm, nwdynam and nwrem. Citing and licenses · Get help · GitHub. Issues with the core go to the nwcommands repository; issues with a model package go to that package's own repository.

This site uses Just the Docs, a documentation theme for Jekyll.