onLoad read-only - InfoPath Dev Sign in | Join | Help in General InfoPath (Entire Site) InfoPath Dev InfoPath Dev is dedicated to bringing you the information and tools you need to be successful in your Microsoft Office InfoPath development projects. Home Blogs Forums Photos Downloads InfoPath Dev » InfoPath » General » onLoad read-only onLoad read-only Last post 04-18-2005 12:52 PM by Shanthi Reddy. 6 replies. Page 1 of 1 (7 items) Sort Posts: Oldest to newest Newest to oldest Previous Next 03-31-2005 06:01 PM potpourri Joined on 03-09-2005 Posts 62 onLoad read-only Reply Contact does anyone know how to set a control to be read-only programmatically?i want so that every non-blank textboxes to be read-only during onLoad... 04-04-2005 05:01 AM In reply to Shanthi Reddy Joined on 08-21-2006 Posts 144 Re: onLoad read-only Mark as Not AnswerMark as Answer... Reply Contact You can do this by having conditional formatting set based on a secondary DOM field value and set that field value as you want it in the onLoad function.There is also the option to set conditional formatting directly and mention that if the field contains some value then make it read only -> but remember if you do this the field will become read only once a user enters some data into the field and clicks out of it.ShanthiInfoPathDev India Shanthi Reddy 04-06-2005 11:06 PM In reply to potpourri Joined on 03-09-2005 Posts 62 Re: onLoad read-only Mark as Not AnswerMark as Answer... Reply Contact hi Shanthi, thanks for the reply :)hmmm i've tried the 2nd approach u suggested before n it really didn't work as what i expected.do u know the semantic for setting a control to be "read-only" programmatically though? 04-10-2005 02:56 PM In reply to Shanthi Reddy Joined on 08-21-2006 Posts 144 Re: onLoad read-only Mark as Not AnswerMark as Answer... Reply Contact The only way i can think of programmatically to set a text box readonly is to set an element value in the DOM and have conditional formatting for the text box based on the value of this elementIf the text box read only status needs to be saved across Infopath sessions then you can either have this value in the secondary DOM and reset it OnLoad or have this value this value in the Main dom so that it is saved.Does this help?ShanthiInfoPathDev India Shanthi Reddy 04-10-2005 09:39 PM In reply to potpourri Joined on 03-09-2005 Posts 62 Re: onLoad read-only Mark as Not AnswerMark as Answer... Reply Contact hey shanti, i think i understand your approach.i'll give it a go and i'll post it again if my case works.thanks again for the tip! :) 04-12-2005 01:27 AM In reply to potpourri Joined on 03-09-2005 Posts 62 Re: onLoad read-only Mark as Not AnswerMark as Answer... Reply Contact shanti, your approach is working well.thanks again for the tips :) 04-18-2005 12:52 PM In reply to Shanthi Reddy Joined on 08-21-2006 Posts 144 Re: onLoad read-only Mark as Not AnswerMark as Answer... Reply Contact Thanks for letting us know. Glad to be of help :)ShanthiInfoPathDev India Shanthi Reddy Page 1 of 1 (7 items) Copyright © 2003-2019 Qdabra Software. All rights reserved.View our Terms of Use.