Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

What is going on here?

Print[InputField[]]
CellPrint[TextCell["my\"text", "Text", ShowStringCharacters -> True]]

enter image description here

If I insert the above code into a blank notebook and run it, only the second cell seems to appear. If I run the code a 2nd time, both Cells are displayed.

How do I correct the code, so the InputField will be displayed the 1st time the code is run?

I am running Mathematica 8 on Windows 7.

share|improve this question
2  
I can not reproduce your problem. I see both the input field and the string 'my"text' on the first evaluation. (V9.0.1 on OS X 10.6.8) –  m_goldberg Jun 18 '13 at 6:09
    
Can anyone confirm the issue in M8? @m_goldberg This is what I get if I run it a second time i.stack.imgur.com/Lt9EY.png –  Liam William Jun 18 '13 at 6:16
    
What your link show is what I see on the first evaluation. –  m_goldberg Jun 18 '13 at 6:18
1  
I can reproduce the problem with v8 on Windows 7. A workaround is to add a tiny pause between the two lines, e.g. Print[InputField[]];Pause[0.0001];CellPrint[blah...] –  Simon Woods Jun 18 '13 at 8:50

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.