  We consider static, cylindrically symmetric configurations in general
relativity coupled to nonlinear electrodynamics (NED) with an arbitrary
gauge-invariant Lagrangian of the form $L_{em}= \Phi(F)$, $F =F_{mn}F^{mn}$. We
study electric and magnetic fields with three possible orientations: radial
(R), longitudinal (L) and azimuthal (A), and try to find solitonic stringlike
solutions, having a regular axis and a flat metric at large $r$, with a
possible angular defect. Assuming the function $\Phi(F)$ to be regular at small
$F$, it is shown that a regular axis is impossible in R-fields if there is a
nonzero effective electric charge and in A-fields if there is a nonzero
effective electric current along the axis. Solitonic solutions are only
possible for purely magnetic R-fields and purely electric A-fields, in cases
when $\Phi(F)$ tends to a finite limit at large $F$. For both R- and A-fields,
the desired large $r$ asymptotic is only possible with a non- Maxwell behaviour
of $\Phi(F)$ at small $F$. For L-fields, solutions with a regular axis are
easily obtained (and can be found by quadratures) whereas a desired large $r$
asymptotic is only possible in an exceptional solution; the latter gives rise
to solitonic configurations in case $\Phi(F) = \const \cdot \sqrt{F}$. We give
an explicit example of such a solution.
