mikromundo Posted July 24, 2021 Share Posted July 24, 2021 It´s possible to change "inputtype" in Runtime ? I have tried 2 ways: TUniEdit(pDbEdit).InputType := 'date'; with TUniControl( pDbEdit ).JSInterface do begin JSConfig('inputType',['date']); end; Quote Link to comment Share on other sites More sharing options...
Hayri ASLAN Posted July 25, 2021 Share Posted July 25, 2021 5 hours ago, mikromundo said: It´s possible to change "inputtype" in Runtime ? I have tried 2 ways: TUniEdit(pDbEdit).InputType := 'date'; with TUniControl( pDbEdit ).JSInterface do begin JSConfig('inputType',['date']); end; Hello You can use below code. with UniEdit1, JSInterface do begin JSAssign('inputEl.dom.type', ['date']); end; Quote Link to comment Share on other sites More sharing options...
mikromundo Posted July 25, 2021 Author Share Posted July 25, 2021 Thanks @Hayri ASLAN but... Quote Link to comment Share on other sites More sharing options...
Sherzod Posted July 25, 2021 Share Posted July 25, 2021 4 hours ago, mikromundo said: Hello, Can you clarify what the problem is? Quote Link to comment Share on other sites More sharing options...
mikromundo Posted July 25, 2021 Author Share Posted July 25, 2021 Hi @Sherzod: inputype.mp4 Quote Link to comment Share on other sites More sharing options...
Sherzod Posted July 25, 2021 Share Posted July 25, 2021 7 minutes ago, mikromundo said: inputype.mp4 6.7 MB · 0 downloads 16 hours ago, Hayri ASLAN said: JSAssign('inputEl.dom.type', ['date']); Your case is not very clear to me. Sorry, why would you want to use this code at all? Quote Link to comment Share on other sites More sharing options...
mikromundo Posted July 25, 2021 Author Share Posted July 25, 2021 Thank you for your attention, @Sherzod See, as I mentioned in the post title I need to change the "InputType" property at runtime. I have a "UniDBEdit" with InputType = text but when the application runs I want to change it to "date" or to "tel" or to "number" ... I hope you got to explain and thank you again for your attention. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.