Translate an ArrayList to a Vector in Java

public static Vector<String> TranslateArrayListToVector(ArrayList<String> tempArray) {
	Vector<String> newArray = new Vector<String>();
	try {		
		for(String temp : tempArray) {
	} catch (Exception e) {
	}finally {
		return newArray;
All code submitted to OpenNTF XSnippets, whether submitted as a "Snippet" or in the body of a Comment, is provided under the Apache License Version 2.0. See Terms of Use for full details.
2 comment(s)Login first to comment...
F van der Linden
(at 10:03 on 04.05.2015)
Another way is by using collections, w

Martin Rolph
(at 03:26 on 03.05.2015)
I think you can just do

doc.replaceItemValue("MultiValueField", new Vector(viewScope.get("Values")));

as a collection will accept another collection in the constructor