PC Review


Reply
Thread Tools Rate Thread

Access2000: reference to control in SQL

 
 
Arvi Laanemets
Guest
Posts: n/a
 
      4th Sep 2006
Hi

My setup is:
I have a form (fmDeviceGroup) with a combo box (where device group is
selected) and a subform (fmDevices), where parameters for selected device
from this group are listed). The form fmDeviceGroup will be later inserted
into unbound multi-sheet form (fmMain).

On form fmDevices is a text box txtParentDeviceGroup, which reflects the
group, selected in parent form, and is used as a source for various
calculations in fmDevices. (DeviceGroup value is a single character, and is
also used as a leftmost character in DeviceID field - which is a master
index field for tblDevices table).

I need a combo box on form fmDevices, to navigate to selected record from
current group. I.e. combo must allow to select from all devices for which
leftmost character of DeviceID is equal with value of txtParentDeviceGroup.
What must be the SQL syntax for this?

SELECT [tblDevices].[DeviceID], [tblDevices].[DeviceName] FROM tblDevices
WHERE (((Left([tblDevices].[DeviceID],1))=???));


Thanks in advance!
--
Arvi Laanemets
( My real mail address: arvi.laanemets<at>tarkon.ee )


 
Reply With Quote
 
 
 
 
Arvi Laanemets
Guest
Posts: n/a
 
      4th Sep 2006
OK, I did find a workaround. I did refer to combo on parent form instead.


--
Arvi Laanemets
( My real mail address: arvi.laanemets<at>tarkon.ee )


"Arvi Laanemets" <(E-Mail Removed)> wrote in message
news:OSGpN9$(E-Mail Removed)...
> Hi
>
> My setup is:
> I have a form (fmDeviceGroup) with a combo box (where device group is
> selected) and a subform (fmDevices), where parameters for selected device
> from this group are listed). The form fmDeviceGroup will be later inserted
> into unbound multi-sheet form (fmMain).
>
> On form fmDevices is a text box txtParentDeviceGroup, which reflects the
> group, selected in parent form, and is used as a source for various
> calculations in fmDevices. (DeviceGroup value is a single character, and
> is also used as a leftmost character in DeviceID field - which is a master
> index field for tblDevices table).
>
> I need a combo box on form fmDevices, to navigate to selected record from
> current group. I.e. combo must allow to select from all devices for which
> leftmost character of DeviceID is equal with value of
> txtParentDeviceGroup. What must be the SQL syntax for this?
>
> SELECT [tblDevices].[DeviceID], [tblDevices].[DeviceName] FROM tblDevices
> WHERE (((Left([tblDevices].[DeviceID],1))=???));
>
>
> Thanks in advance!
> --
> Arvi Laanemets
> ( My real mail address: arvi.laanemets<at>tarkon.ee )
>



 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Access2000, contionous form: Determining destination control and it's bookmark in LostFocus event Arvi Laanemets Microsoft Access 5 25th Mar 2005 08:42 PM
Re: Access2000, contionous form: Deleting field value when combo is used as control Arvi Laanemets Microsoft Access 0 25th Mar 2005 10:06 AM
1 Oct 2003, Access2000, Compile error while using .mde file of Access2000. Sham Yemul Microsoft Access 1 2nd Oct 2003 04:49 PM
1 Oct 2003, Access2000, Compile error while using .mde file of Access2000. Sham Yemul Microsoft Access VBA Modules 1 2nd Oct 2003 04:49 PM
1 Oct 2003, Access2000, Compile error while using .mde file of Access2000. Sham Yemul Microsoft Access Form Coding 1 2nd Oct 2003 04:49 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:49 PM.