Results 1 to 3 of 3
  1. #1
    nahum abramovich is offline Advanced Beginner
    Windows 7 64bit Access 2016
    Join Date
    Jun 2018
    Posts
    62

    label appear

    HI

    thanks for your help!

    i need guidance for making text box or label appear (on form) when 4 condition (from query) is met - This is just for showing a sign that pops up (doesn't have to be text inside).

    i tried to do this with c
    onditional Formatting but my knowledge of Access is not so good...


    i tried something like this.....(inside expression builder)....

    [B]iif( [q]! [a]= "Danny" And [q]! = "Triangular" And [q]! [c] = "Red" And [q]! [d] > "1", "ATTENTION" , " " )



    i tried to do this also in label/text box control source .....


    And that's probably not the way to do it ...

    Would appreciate help

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,550
    Make a routine for the action,showLbl()

    Code:
    sub ShowLbl()
    Label.visible= txtBox <>"Danny" And txtBox2<> "Triangular" And txtBox3= "Red" And txtBox4 > 1
    end sub
    then call it when things change,
    OnCurrent event,
    textbox afterupdate,

    anthing that could alter the condition.

  3. #3
    accesstos's Avatar
    accesstos is offline Expert
    Windows XP Access 2007
    Join Date
    Dec 2018
    Location
    Greece
    Posts
    551
    An other way without VBA:

    Put the condition in a new field (say [Msg]) of the query and then bind the textbox on it.

    Field expression:
    Code:
    Msg: iif([q]![a]="Danny" And [q]![b]="Triangular" And [q]![c]="Red" And [q]![d]>"1","ATTENTION","")
    PS. Note that the [q]![d]>"1" is not the same with [q]![d]>1

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 6
    Last Post: 10-10-2017, 03:01 AM
  2. Replies: 3
    Last Post: 10-08-2017, 12:53 PM
  3. Replies: 1
    Last Post: 04-25-2014, 11:41 AM
  4. Label Help
    By rcotero in forum Access
    Replies: 2
    Last Post: 11-05-2010, 01:39 PM
  5. Saving Label on the Fly
    By frobro390 in forum Forms
    Replies: 3
    Last Post: 10-07-2010, 10:52 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums