function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Josip Juric87Josip Juric87 

Hybrid Remote app with Community and custom VF login page

I am trying to add a custom Visualforce login page to my hybrid-remote app, which is connected to a SF community. What I have done is, created a Visualforce page, which collects the User's username and password and calls the following controller method:
 
public PageReference doLogin() {
	return Site.login(username, password, null);
}

When I try to login through a browser into the community, it works well. But, when I try to do it through the mobile app (created with SF Mobile SDK, i.e. forceios CLI), it gives me after clicking the login-button the following message:
"Can't connect to salesforce: The URL can't be shown".

What have I missed?
Thanks!
Phil Bergner 8Phil Bergner 8
Did you set the startURL in the bootconfig.json file in your app?
Abdul Khader CKAbdul Khader CK
Hi Josip, can you pls update us how you resolve this issue ? we are also facing same issue