Thanks that is basically what i was in the process of doing. a method to run in 'On Shut Down', which (when the component is not compiled) gets the code of the method, and writes to a text file - but in the database folder of the component.
The resource folder gets shared to clients, and there is no reason for a client to have this source code. Chip On Tue, 21 Aug 2018 10:38:05 -0600, Dani Beaubien wrote: > I have had to do this. I store a copy of the methods I need in a > folder in the Resources folder. > > Only downside is that the code is outside of the structure so the > maintenance is a bit more effort. You could add a bit of code to the > On Exit method on the component that updates the copy of the method > on disk from the method in 4D. That helps to make maintenance a bit > easier. > > Dani > > >> On Aug 21, 2018, at 10:23 AM, Chip Scheide via 4D_Tech >> <4d_tech@lists.4d.com> wrote: >> >> I have written code which injects (creates) needed methods in a host >> database. >> The code for injecting works interpretedly, I was just testing the >> component compiled, and ran into an error. I am getting the code of a >> method in the component, and then injecting it into the host. >> METHOD GET CODE("Methodname";$Text) >> METHOD SET CODE("Methodname";$Text;*) >> >> And of course, once the component is compiled, I can no longer GET the >> method's code (duh!). >> >> So, anyone who is doing this, how are you going about storing the code >> to inject? >> - written to a text file? >> - in a data file --problematic for a component >> - ??? >> >> Thanks >> >> --------------- >> Gas is for washing parts >> Alcohol is for drinkin' >> Nitromethane is for racing >> ********************************************************************** >> 4D Internet Users Group (4D iNUG) >> Archive: http://lists.4d.com/archives.html >> Options: https://lists.4d.com/mailman/options/4d_tech >> Unsub: mailto:4d_tech-unsubscr...@lists.4d.com >> ********************************************************************** > > --------------- Gas is for washing parts Alcohol is for drinkin' Nitromethane is for racing ********************************************************************** 4D Internet Users Group (4D iNUG) Archive: http://lists.4d.com/archives.html Options: https://lists.4d.com/mailman/options/4d_tech Unsub: mailto:4d_tech-unsubscr...@lists.4d.com **********************************************************************