Android Question error activity pause

SCIS

Active Member
Licensed User
Longtime User
B4X:
LogCat connected to: B4A-Bridge: samsung SM-G925F
--------- beginning of main
--------- beginning of system
** Activity (main) Create, isFirst = true **
** Activity (main) Resume **
** Service (service1) Create **
** Service (service1) Start **
Connected to B4A-Bridge (Wifi)
Installing file.
** Activity (main) Pause, UserClosed = false **
PackageAdded: package:b4a.example
** Activity (main) Create, isFirst = true **
** Activity (main) Resume **
** Activity (main) Pause, UserClosed = true **
Error occurred on line: 92 (main)
java.lang.ClassCastException: java.lang.String cannot be cast to android.widget.TextView
    at anywheresoftware.b4a.objects.TextViewWrapper.getText(TextViewWrapper.java:35)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:636)
    at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:302)
    at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:238)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:121)
    at b4a.example.registrerentc.initializeGlobals(registrerentc.java:306)
    at b4a.example.registrerentc.afterFirstLayout(registrerentc.java:97)
    at b4a.example.registrerentc.access$100(registrerentc.java:17)
    at b4a.example.registrerentc$WaitForLayout.run(registrerentc.java:78)
    at android.os.Handler.handleCallback(Handler.java:739)
    at android.os.Handler.dispatchMessage(Handler.java:95)
    at android.os.Looper.loop(Looper.java:158)
    at android.app.ActivityThread.main(ActivityThread.java:7224)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
** Activity (registrerentc) Create, isFirst = true **
** Activity (main) Resume **
B4X:
Sub Registreren_Click

    'Wanneer er op de knop registreren word gedrukt sluit het mainscherm.
    Activity.finish
   
    'Start de pagina om te registreren op.
    StartActivity(RegistrerenTC)
   
End Sub
 
Upvote 0

mc73

Well-Known Member
Licensed User
Longtime User
Somehow I think that you're trying to set the password string to an edittext, and not its property edittext.text.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…