How do I format an image field so that the user inserted image is centered in the field?

Avatar

Avatar
Boost 1
Level 1
pchvpi
Level 1

Like

1 like

Total Posts

1 post

Correct reply

0 solutions
Top badges earned
Boost 1
View profile

Avatar
Boost 1
Level 1
pchvpi
Level 1

Like

1 like

Total Posts

1 post

Correct reply

0 solutions
Top badges earned
Boost 1
View profile
pchvpi
Level 1

08-04-2015

I've tried center anchoring it but it still upper left justifies any image inserted in the image field. 

Accepted Solutions (0)

Answers (2)

Answers (2)

Avatar

Avatar
Validate 1
Level 2
MHaywood323
Level 2

Likes

3 likes

Total Posts

22 posts

Correct reply

1 solution
Top badges earned
Validate 1
Boost 3
Boost 1
Affirm 1
View profile

Avatar
Validate 1
Level 2
MHaywood323
Level 2

Likes

3 likes

Total Posts

22 posts

Correct reply

1 solution
Top badges earned
Validate 1
Boost 3
Boost 1
Affirm 1
View profile
MHaywood323
Level 2

14-04-2015

I normally use the old Text Field Trick in LiveCycle.

Create a new Text Field, Set your Text Justification Options and then change the Field to Image Field.

It will retain the Text Field Settings from before.. Used that "trick" many times.

Avatar

Avatar
Establish
MVP
_Bruce_Robertson
MVP

Likes

271 likes

Total Posts

1,782 posts

Correct reply

372 solutions
Top badges earned
Establish
Give Back 25
Give Back 10
Give Back 5
Give Back 3
View profile

Avatar
Establish
MVP
_Bruce_Robertson
MVP

Likes

271 likes

Total Posts

1,782 posts

Correct reply

372 solutions
Top badges earned
Establish
Give Back 25
Give Back 10
Give Back 5
Give Back 3
View profile
_Bruce_Robertson
MVP

09-04-2015

If your image field has "use original size" as a sizing option then the image will end up in the top left corner.  If you add the following JavaScript in the initialise event of the image field then it will be centered.

this.para.vAlign = "middle";

this.para.hAlign = "center";

 

Regards

Bruce