• Proper Way to SetProperty

    Author
    Topic
    #460457

    In a macro, I set
    Action: SetProperty
    In Arguments, I set
    Control Name: Forms![frm成交].[Caption]
    Property: Enabled
    Value: “Dealing”
    I keep receiving the error shown in the screenshot.
    Please help.
    Thanks.
    Armstrong

    Viewing 0 reply threads
    Author
    Replies
    • #1164532

      In a macro, I set
      Action: SetProperty
      In Arguments, I set
      Control Name: Forms![frm成交].[Caption]
      Property: Enabled
      Value: “Dealing”
      I keep receiving the error shown in the screenshot.
      Please help.
      Thanks.
      Armstrong

      What is the control name on the form? You should refer to the control name’s caption like:

      Forms![frm成交]!Controlname.[Caption]

      • #1164534

        What is the control name on the form? You should refer to the control name’s caption like:

        Forms![frm成交]!Controlname.[Caption]

        Thanks for your help. How to find the Controlname? I suppose [frm成交] is the Controlname. [frm成交] is the name of the form which calls the macro.
        Armstrong

        • #1164536

          Thanks for your help. How to find the Controlname? I suppose [frm成交] is the Controlname. [frm成交] is the name of the form which calls the macro.
          Armstrong

          So you want to change the forms caption?

          Again i ask why use macros, it’s easier usingvba code and you have far more control over vba code than macros.

          By the way, why do you wish to change the form’s caption?

          • #1164537

            So you want to change the forms caption?

            Again i ask why use macros, it’s easier usingvba code and you have far more control over vba code than macros.

            By the way, why do you wish to change the form’s caption?

            Hi Patt,
            Thanks for your interesting questions.
            >So you want to change the forms caption?
            Just for my study and test. My actual aim is to change the order of the display.

            >Again i ask why use macros, it’s easier usingvba code and you have far more control over vba code than macros.
            Well, it’s because I’m reading chapters on macros.

            Armstrong

          • #1164538

            Hi Patt,
            I just find the solution.
            The proper way to the caption:
            —————————
            Control Name: [blank]
            Property: Caption
            Value: Dealing
            —————————
            It works for me.
            Thanks for your help.
            Armstrong

            • #1164602

              Hi Patt,
              I just find the solution.
              The proper way to the caption:
              —————————
              Control Name: [blank]
              Property: Caption
              Value: Dealing
              —————————
              It works for me.
              Thanks for your help.
              Armstrong

              Glad you found it.

    Viewing 0 reply threads
    Reply To: Proper Way to SetProperty

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: