added stuff to load the code into the text region