Hidden Fields in NiceForm

Issues related to label design (working with databases, data processing, RFID encoding etc.) and printing (from NiceLabel Express, NiceLabel Pro, NiceForm and NicePrint)

Moderators: Georges, milos, NiceLabel Support Team

Post Reply
rlmeyer
Enthusiast
Posts: 11
Joined: Wed Dec 14, 2011 8:48 pm

Hidden Fields in NiceForm

Post by rlmeyer » Wed Dec 14, 2011 9:07 pm

I was wondering if you can create hidden field in NiceForm? I have tried hiding fields behind other objects. The hidden fields are always on Top, even if I set them "To Back". If you set the text and the background of the field to the same color as the form background you still have the field outline that shows up.

Here is the situation that has lead me to try and create hidden fields. I have a form that gets data from an Access DB via a table. I created a few edit fields that are linked to fields in the DB, so when the incremental search happens the data is automatically transferred to the correct edit fields. Also, the edit fields are linked to variables. Sometimes the data needed on the form is not located in the DB, so I have to change the text in the edit fields. When you try to change the edit fields linked to the DB nothing happens. I tried a work around by creating more edit fields linked to the same variables as the DB linked edit fields. I can edit the text in those fields without a problem. So I was going to hidden the DB linked edit fields and just change the other edit fields if need be.

I hope this all makes sense and there may be a better way than I have laid out. I would appreciate in help you can provide.

User avatar
dado
NiceLabel Development
NiceLabel Development
Posts: 691
Joined: Tue Sep 12, 2006 12:50 pm
Location: Kranj, Slovenia
Contact:

Re: Hidden Fields in NiceForm

Post by dado » Wed Dec 14, 2011 10:14 pm

Unfortunately you cannot hide elements in current NiceForm.

The only way is to place your edit field under another object like button or another edit field. If you put the edit field under the preview or under the frame then your edit filed will still be visible.

To connect a variable to the database field, place a table object on the form and under its properties select Columns tab. There you can connect a variable with the edit field. Now just use the variable in any edit field and you will be able to modify it.

Regards

Damjan

User avatar
Saso
NiceLabel
NiceLabel
Posts: 2974
Joined: Mon Sep 04, 2006 8:09 am
Contact:

Re: Hidden Fields in NiceForm

Post by Saso » Thu Dec 15, 2011 9:03 am

You cannot *officially* hide the objects.
There is a workaround. ;-)

To hide an object, you could do the following:
  1. Create a dummy variable.
  2. Place a text object above the object you want to hide and link it to the dummy variable.
  3. Format the text object to have the same background as is your form background. You have to disable "transparent color" in text properties -> style tab -> background.
  4. If you set spaces as value for a dummy value, the text object will display over the underlying objects, hiding them.
  5. If the dummy variable doesn't have any value, the underlying objects are seen.
  6. This workaround might not work for all object types (e.g. buttons).
hiding objects.png
hiding objects.png (15.79 KiB) Viewed 6762 times
See an attached form sample for how it is done.
Attachments
Hidden Objects.xff
(5.8 KiB) Downloaded 468 times
Saso Fleiser
Senior Technical Product Specialist

rlmeyer
Enthusiast
Posts: 11
Joined: Wed Dec 14, 2011 8:48 pm

Re: Hidden Fields in NiceForm

Post by rlmeyer » Thu Dec 15, 2011 2:28 pm

That's awesome guys!!! Thanks for the replies. I connected the variable to the table and it works great. I know you can do a lot with VBScript or Python in Niceform, but hidden fields come in really handy sometimes. Maybe after I learn a lot more about Nicelablel, I will find no need for hidden fields. I appreciate all the help!

Thanks,
Richard

Uros
Enthusiast
Posts: 6
Joined: Thu Nov 28, 2013 10:48 am

Re: Hidden Fields in NiceForm

Post by Uros » Wed Jul 23, 2014 10:34 am

On my label is an image and over this image is a text object, which value is set by a variable. When text object will have a value will cover/hide the image. But on text object I can't find the settings for background. There is setting just for font color? :?:
I'm using NiceLabel pro 6.2.

Matt
NiceLabel
NiceLabel
Posts: 185
Joined: Mon Apr 28, 2014 10:56 pm

Re: Hidden Fields in NiceForm

Post by Matt » Wed Jul 23, 2014 5:07 pm

Hello,
The approach to controlling whether objects are printed from the NiceLabel Designer would be a bit different than the approach from NiceForm (demonstrated earlier).

If you associate a label design variable with your design object (ie: Picture, Text), you can simply control whether that object is printed based on the value you provide to the variable at print-time (likely a value you're providing from your NiceForm).
Capture1.JPG
Capture1.JPG (26.15 KiB) Viewed 5139 times
The value given to the variable at print time determines which image gets printed:
Capture2.JPG
Capture2.JPG (25.01 KiB) Viewed 5139 times
...if no value is given to the variable at print-time, then the image is not printed on the label.
NiceLabel
Image

Uros
Enthusiast
Posts: 6
Joined: Thu Nov 28, 2013 10:48 am

Re: Hidden Fields in NiceForm

Post by Uros » Fri Jul 25, 2014 7:24 am

oh, I overloodked, that was solution for NiceForm. #-o
Yes, in the end I used that solution. But is there possibility to integrate/save the picture in label and link it to variable? The value of variable would be used as condition for visibilty of the picture.

Post Reply