How to split string in NSIS -
string "jdbc:postgresql://localhost:5432/databasename"
my requirement databasename above string.
i tried below link not worked.
${explode} $0 "jdbc:postgresql://localhost:5432/" "$v1"
it give error invalid command.
http://nsis.sourceforge.net/explode
how possible in nsis language. i'm not more familiar nsis language. please needful help. in advance.
if need rest of string after last /
can use basic nsis string handling:
section strcpy $0 "jdbc:postgresql://localhost:5432/databasename" strcpy $1 0 loop: intop $1 $1 - 1 strcpy $2 $0 1 $1 strcmp $2 '/' found strcmp $2 '' stop loop found: intop $1 $1 + 1 stop: strcpy $2 $0 "" $1 detailprint "|$2|" sectionend
Comments
Post a Comment