tags:

views:

22

answers:

2
+1  Q: 

LEft operand error

Hello,

   I need to change only xoffset of my textfield on a particular event . I am writing the following line .

fileNametext.frame.origin.x = 300.0;

But I am getting the following error .

error: lvalue required as left operand of assignment

Can somebody please help me ? Thanks in advance .

+3  A: 

Try:

fileNametext.frame = CGFrameMake(300, fileNametext.frame.origin.y, fileNametext.frame.size.width, fileNametext.frame.size.height);
Josh Hinman
A: 

Given that error, I'd say that 'x' is either an accessor method or a read-only property. Try what Josh said.

Sam Dufel