I\'m modifying an old Android application. I have a GPS lat and long being stored in a string value and displayed to the user in a non-editable text box when it resolves. I wa
provide a context before
getSystemService(Context.CLIPBOARD_SERVICE);
like
Context context = ...; ClipboardManager clipboard = (ClipboardManager) context.getSystemService(Context.CLIPBOARD_SERVICE);