Results 1 to 7 of 7
  1. #1
    Join Date
    Apr 2004
    Posts
    29

    Unanswered: Own minded fields

    I got 'FieldC' on a form that under 'Control Source' is bound to this formula expression =[FieldA]+[FieldB]

    FieldA and FieldB default values are set to =Zero on the table, and the form is set to fetch the default values as soon as you open it.

    When I open the form, FieldC shows blank, even though a Zero is shown in FieldA/B, and FieldC default value on the form is set to Zero. Unless I type something FieldC will remain blank. I want it to always show something like some of the other fileds that are bound to a formula.

    Any ideas, thank you!

  2. #2
    Join Date
    Sep 2003
    Location
    MN US
    Posts
    313

    Re: Own minded fields

    Originally posted by brduran
    I got 'FieldC' on a form that under 'Control Source' is bound to this formula expression =[FieldA]+[FieldB]

    FieldA and FieldB default values are set to =Zero on the table, and the form is set to fetch the default values as soon as you open it.

    When I open the form, FieldC shows blank, even though a Zero is shown in FieldA/B, and FieldC default value on the form is set to Zero. Unless I type something FieldC will remain blank. I want it to always show something like some of the other fileds that are bound to a formula.

    Any ideas, thank you!
    You could do this:

    =nz([FieldA]+[FieldB], "0")

    nz checks for null values.

    HTH

  3. #3
    Join Date
    Feb 2004
    Posts
    142

    Re: Own minded fields

    Originally posted by brduran
    I got 'FieldC' on a form that under 'Control Source' is bound to this formula expression =[FieldA]+[FieldB]

    FieldA and FieldB default values are set to =Zero on the table, and the form is set to fetch the default values as soon as you open it.

    When I open the form, FieldC shows blank, even though a Zero is shown in FieldA/B, and FieldC default value on the form is set to Zero. Unless I type something FieldC will remain blank. I want it to always show something like some of the other fileds that are bound to a formula.

    Any ideas, thank you!
    What do you mean by fetch? Are the controls A and B bound to a table or are you populating them in code?

    If you are do it in code sometimes you need to issue a me.requery after you load the form.
    KC

  4. #4
    Join Date
    Apr 2004
    Posts
    29

    Re: Own minded fields

    Originally posted by AZ KC
    What do you mean by fetch? Are the controls A and B bound to a table or are you populating them in code?
    They're bound to a table.

  5. #5
    Join Date
    Feb 2004
    Posts
    142

    Re: Own minded fields

    Originally posted by brduran
    They're bound to a table.
    I could not recreate the issue in a bound form. However the NZ function most likely will work.
    KC

  6. #6
    Join Date
    Apr 2004
    Posts
    29

    Re: Own minded fields

    Originally posted by cpgospi
    You could do this:

    =nz([FieldA]+[FieldB], "0")

    nz checks for null values.

    HTH
    Added your suggestion in Default Value, and nothing.

  7. #7
    Join Date
    Apr 2004
    Posts
    29

    Talking

    The name of the field, supposed to be FieldA, got FieldAS. I guess the S got squized in since is next to A, and is making me look like a FieldASS.

    Thank you!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •