It is currently 9 June 2025, 1:57 Advanced search

Custom Login (using Win10 & Zen)

Questions and answers on how to best use Instant Developer

Custom Login (using Win10 & Zen)

Postby john w » 21 November 2015, 16:52

I want to customize my login form. I have copied the login1.htm to my /custom folder. So far so good.

I then edit the login1.htm. The first thing I wanted was to delete the 'Powered by Instant Developer" image. I had to delete the line of html code having the image reference. So far so good

I then wanted to change the 'start page' hyperlink to my url. This is where it starts to give problems. I could change the code and save it. However at runtime it changes the url back to programma. Hmmm codes right but url changes at run time.

I then deleted the line of html code with the reference. The link disappears entirely not what I want but better than the programma link. However, after I continue to debug a few times the line shows up again even though it not in the code. hmmmm its getting it from somewhere.

FInally I want to have an error message sent to the user when the login fails telling them why it failed. I set a message box but it does not not show. How do I get a message to the user that the login failed and why.

I had to upload the login html as a .zip file since I cannot post an .htm or .txt file. I posted an image of the InDe onLogin event code. Thanks
Attachments
2015-11-21 10_51_13-Pro Gamma Instant Developer 14.5 - Solomon2015.idp.png
Image of onlogin event
2015-11-21 10_51_13-Pro Gamma Instant Developer 14.5 - Solomon2015.idp.png (59.35 KiB) Viewed 9384 times
login1.zip
Contains login.htm
(1.69 KiB) Downloaded 486 times
Regards

John W
User avatar
john w
 
Posts: 851
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA

Re: Custom Login (using Win10 & Zen)

Postby d.arrivabene » 24 November 2015, 8:54

You have copied the login1.htm from Template folder or the output folder produced by InDe during compiling the app?

In general, if you need to customize a template file (such as login1.htm) you have to take the file from Template folder that you can find into C:/program files (x86)/INDE/CURRENT/Template/Theme/Zen. The reason is that only the files listed here have macros that InDe replace with any parameter found and set by the developer.

To show an error or message during the login process, you can use the setLoginMessage method that you can find here: http://doc.instantdeveloper.com/eng/?ARTID=D162D395-982C-484A-BD60-FA888CBA84D8&LANG=eng

Hope it helps :)
User avatar
d.arrivabene
Pro Gamma
Pro Gamma
 
Posts: 1232
Joined: 5 October 2011, 8:36
Location: Bologna

Re: Custom Login (using Win10 & Zen)

Postby john w » 24 November 2015, 13:51

D.

As I outline I took all those steps, I have also tried setLoginMessage. When I run the app and check the login debugger it shows the message does run, however it does not show(display) on the Login form or InDe screen.

I also do not know why the form shows some lines of code that do not exist in the htmi. They have in fact been deleted. But in running the app they reappear (at runtime). The seem to be loading from somewhere.

Thanks, if you have other ideas let me know, in the meantime I will keep looking as well.
Regards

John W
User avatar
john w
 
Posts: 851
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA

Re: Custom Login (using Win10 & Zen)

Postby ljwilson » 27 November 2015, 15:02

John,

I haven't tried it with ZEN, but with the older Seattle theme in addition to Login1.htm I also put a copy of rtcconst.eng in my custom folder. Search your inde program folder for this filename--for c# mine is in "C:\Program Files (x86)\INDE\CURRENT\Template\CSharp". Inside that file you will need to change the line (line number 143 in my file) that starts with:

4D691B94-E528-4AEC-B319-0F18A9049DB3

This is the same guid that Login1.htm uses:
Code: Select all
MainFrm.RTCObj.GetConst("4D691B94-E528-4AEC-B319-0F18A9049DB3"


...jack
ljwilson
 
Posts: 787
Joined: 26 November 2013, 14:15

Re: Custom Login (using Win10 & Zen)

Postby john w » 27 November 2015, 15:54

jack - Thanks I will give that try and see if I can get it running.
Regards

John W
User avatar
john w
 
Posts: 851
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA

Re: Custom Login (using Win10 & Zen)

Postby john w » 12 December 2015, 15:57

jack

I finally got back to this project. I tried adding the rtcconst.eng into my custom site. I made the change I wanted to the referenced GUID and it works.

Thanks so much!!! I dont know how you discovered this as the place to make the change, hats off. There is lot going on in that file, any other things that are useful in it.

David.... this may be a useful tip to others who are not familiar with rtcConst.eng file, the need to make changes in it as well as the html and adding it to the custom folder.
Regards

John W
User avatar
john w
 
Posts: 851
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA


Return to Tips & Tricks

Who is online

Users browsing this forum: No registered users and 9 guests

cron