The solutions to electromagnetic compatibility problems are given by combining vector finite element method (VFEM) with neural network (NN). Two methods for this combination are presented. Solution results compare well with VFEM and analytical solutions. The first method (Method 1) eliminates the need to store the memory exhaustive global matrix of VFEM. This is possible with NN since back propagation needs the estimated vector in order to compare with the right side vector. The second method (Method 2) stores the VFEM global matrix in a compact form using the sparsity and symmetry of the global matrix and then uses the stored matrix elements as the neuron's weights for the NN architecture. Further, preconditioning techniques are used to accelerate the convergence of the training algorithm. To demonstrate the applicability and usefulness of the methods, various structures are solved including crosstalk on printed circuit board, radar cross section of lossy and lossless cylinders with apertures and penetrated fields inside these cylinders.