Results 1 to 4 of 4

Thread: Retrieving values passed to a command object

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    May 2005
    Posts
    324

    Retrieving values passed to a command object

    I have an MSHFlexGrid control whose datasource is a stored procedure that takes 3 parameters. When I add or delete records I want to close and reopen the datasource, and obviously have to reprovide the correct parameters.
    Initially this was fine, as the parameters were provided by controls on the form from which the dataentry form was launched.
    The trouble is that now the form can be launched from a number of different places, so the values for the parameters come from different places. What I would like to do therefore is, before closing the command object I want to find out what parameters are being passed to it so that I can immediately reopen it with the same parameters. I thought I could do this with Dataenvironment1.commands("NameOfCommand").Parameters(1) etc. but that returns an empty string. So what do I do?

  2. #2
    PowerPoster
    Join Date
    Dec 2004
    Posts
    25,618

    Re: Retrieving values passed to a command object

    store the parameters in a table in the database

    pete

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    May 2005
    Posts
    324

    Re: Retrieving values passed to a command object

    Yes, I could do that, or create public variables for them. I just wondered if you could find out what the parameters currently being passed are, and pass the same ones again when you reopen. Ah well.

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    May 2005
    Posts
    324

    Resolved Re: Retrieving values passed to a command object

    I've just used public variables, and it's fine. Why can't you retrieve the parameters passed to a command object though?

Posting Permissions

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



Click Here to Expand Forum to Full Width