This project has moved and is read-only. For the latest updates, please go here.

Hide Textfield if it's empty

Mar 13, 2015 at 11:18 AM
I want to hide a text field in DispForm.aspx if the value of this textfield is empty. How can I manage this?

Thank you very much in advance!
Mar 16, 2015 at 9:32 AM
Hello again

This is my code, which isn't workling:

``` var abgemeldetEMAPolizei = SPUtility.GetSPField('EMA / BMA abgemeldet Polizei');
var abgemeldetvalue = abgemeldetEMAPolizei.LabelRow.children().next().text().trim();
if(abgemeldetvalue === null)
` Can you help me out here? Thank you!
Mar 16, 2015 at 3:21 PM
Oh - I just found the solution by myself:

the If-Statement should look like this:

if(abgemeldetvalue === "")

Like this it's working.
Marked as answer by MELY on 3/16/2015 at 7:21 AM
Mar 16, 2015 at 8:24 PM
Great I'm glad you got it working! Looks like you're getting the handle of JavaScript :)