From: iccsi on
I would like to use choose function from dropdown box column 4.
for example:

Choose([myform[![mydropdown]![column](4), myvalue = "something",
myvalue = "that thing")
Can I do above using choose function?
If I can, can you please advise the proper syntax?
If not, any other solution for this?


Your help is great appreciated,

From: Tom van Stiphout on
On Wed, 19 May 2010 07:37:48 -0700 (PDT), iccsi <inungh(a)gmail.com>
wrote:

Choose(Me.myDropdown.Column(4), "TextForIndex0", "TextForIndex1",
"TextForIndex2, ...etc)

-Tom.
Microsoft Access MVP


>I would like to use choose function from dropdown box column 4.
>for example:
>
>Choose([myform[![mydropdown]![column](4), myvalue = "something",
>myvalue = "that thing")
>Can I do above using choose function?
>If I can, can you please advise the proper syntax?
>If not, any other solution for this?
>
>
>Your help is great appreciated,
From: Daryl S on
icssi -

If the fourth column of your drop-down contains only integers, and your
choose function will have all the choices for the possible integers, then you
can do this. Remember that columns in combo-boxes are zero-based, so
..Column(0) is the first column, and .Column(3) is the fourth column of the
selected record (assuming multi-selections is not allowed).

If you have problems, post your code so we can help.

--
Daryl S


"iccsi" wrote:

> I would like to use choose function from dropdown box column 4.
> for example:
>
> Choose([myform[![mydropdown]![column](4), myvalue = "something",
> myvalue = "that thing")
> Can I do above using choose function?
> If I can, can you please advise the proper syntax?
> If not, any other solution for this?
>
>
> Your help is great appreciated,
>
> .
>
From: iccsi on
On May 19, 11:27 am, Daryl S <Dar...(a)discussions.microsoft.com> wrote:
> icssi -
>
> If the fourth column of your drop-down contains only integers, and your
> choose function will have all the choices for the possible integers, then you
> can do this.  Remember that columns in combo-boxes are zero-based, so
> .Column(0) is the first column, and .Column(3) is the fourth column of the
> selected record (assuming multi-selections is not allowed).
>
> If you have problems, post your code so we can help.
>
> --
> Daryl S
>
>
>
> "iccsi" wrote:
> > I would like to use choose function from dropdown box column 4.
> > for example:
>
> > Choose([myform[![mydropdown]![column](4), myvalue = "something",
> > myvalue = "that thing")
> > Can I do above using choose function?
> > If I can, can you please advise the proper syntax?
> > If not, any other solution for this?
>
> > Your help is great appreciated,
>
> > .- Hide quoted text -
>
> - Show quoted text -

I use choose function in a query. The syntax failed when I tried to
run the query like following:

Choose([Forms]![MyForm]![MyDropDown]![Column](3),
[tblMyTable].[MyID] In (Select MyID from tblMyTable where GP1 = True),
[tblMyTable].[MyID] In (Select MyID from tblMyTable where GP2 = True))


thanks again,
From: Tom van Stiphout on
On Wed, 19 May 2010 11:39:42 -0700 (PDT), iccsi <inungh(a)gmail.com>
wrote:

Rather than your attempt at a subselect you can use DLookup function.

I also have a feeling there should be a simpler solution with joins,
but it would require more information about your database structure to
determine that for sure.

-Tom.
Microsoft Access MVP



>On May 19, 11:27�am, Daryl S <Dar...(a)discussions.microsoft.com> wrote:
>> icssi -
>>
>> If the fourth column of your drop-down contains only integers, and your
>> choose function will have all the choices for the possible integers, then you
>> can do this. �Remember that columns in combo-boxes are zero-based, so
>> .Column(0) is the first column, and .Column(3) is the fourth column of the
>> selected record (assuming multi-selections is not allowed).
>>
>> If you have problems, post your code so we can help.
>>
>> --
>> Daryl S
>>
>>
>>
>> "iccsi" wrote:
>> > I would like to use choose function from dropdown box column 4.
>> > for example:
>>
>> > Choose([myform[![mydropdown]![column](4), myvalue = "something",
>> > myvalue = "that thing")
>> > Can I do above using choose function?
>> > If I can, can you please advise the proper syntax?
>> > If not, any other solution for this?
>>
>> > Your help is great appreciated,
>>
>> > .- Hide quoted text -
>>
>> - Show quoted text -
>
>I use choose function in a query. The syntax failed when I tried to
>run the query like following:
>
>Choose([Forms]![MyForm]![MyDropDown]![Column](3),
>[tblMyTable].[MyID] In (Select MyID from tblMyTable where GP1 = True),
>[tblMyTable].[MyID] In (Select MyID from tblMyTable where GP2 = True))
>
>
>thanks again,