Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

warning message

pooterpooter Member Posts: 2
In my report called rptStockFlow i have the products
underlined with red if balance is not equal to in - out:


Const conNormal = 400
Const conHeavy = 900 ' exra bold

Private Sub Detail_Format(Cancel As Integer, FormatCount As

Integer)
If Me![balance] <> Me!In - Me!Out Then
Me!balance.FontWeight = conHeavy
Me!balance.ForeColor = 32768
Else
Me!balance.FontWeight = conNormal
Me!balance.ForeColor = 0
End If
If Me![balance] <> Me!OnStore Then
Me!OnStore.FontWeight = conHeavy
Me!OnStore.ForeColor = 255
Else
Me!OnStore.FontWeight = conNormal
Me!OnStore.ForeColor = 0
End If
End Sub


is it possible in the Onopen event of the report to create
some code that sends a warning message on the screen,that something is
wrong with the balance of the goods ?




Comments

  • aatkbdaatkbd Member Posts: 42
    : In my report called rptStockFlow i have the products
    : underlined with red if balance is not equal to in - out:
    :
    :
    : Const conNormal = 400
    : Const conHeavy = 900 ' exra bold
    :
    : Private Sub Detail_Format(Cancel As Integer, FormatCount As
    :
    : Integer)
    : If Me![balance] <> Me!In - Me!Out Then
    : Me!balance.FontWeight = conHeavy
    : Me!balance.ForeColor = 32768
    : Else
    : Me!balance.FontWeight = conNormal
    : Me!balance.ForeColor = 0
    : End If
    : If Me![balance] <> Me!OnStore Then
    : Me!OnStore.FontWeight = conHeavy
    : Me!OnStore.ForeColor = 255
    : Else
    : Me!OnStore.FontWeight = conNormal
    : Me!OnStore.ForeColor = 0
    : End If
    : End Sub
    :
    :
    : is it possible in the Onopen event of the report to create
    : some code that sends a warning message on the screen,that something is
    : wrong with the balance of the goods ?
    :
    :
    :
    :
    :
    I would have a global boolean variable that the "on format" event could swtich to true and then code an "on activate" event to display a message based on if the boolean variable is true.

    that or raise your own error and then place code in the "on error" event.
Sign In or Register to comment.