Re: datagrid combobox question
From: Doug Bell (dug_at_bigpond)
Date: 11/04/04
- Next message: Ken Tucker [MVP]: "Re: Problems with SQL Statement"
- Previous message: james: "Problems with SQL Statement"
- In reply to: Doug Bell: "Re: datagrid combobox question"
- Next in thread: Cor Ligthert: "Re: datagrid combobox question"
- Reply: Cor Ligthert: "Re: datagrid combobox question"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 4 Nov 2004 11:33:16 +1100
Ken,
Sorry the Combo is not bound to the Locations Table.
The Locations Table is the datasource for the Combo Box.
The combo Box is bound to the Location field in the Order Details Table.
Does this make more sense?
"Doug Bell" <dug@bigpond> wrote in message
news:eE5ytUgwEHA.1260@TK2MSFTNGP12.phx.gbl...
> Ken,
>
> I am still not sure what you are saying.
>
> My combo box is bound to data not a string list and it is setting the
value
> just for the row that it is displayed within
>
> I already have a datagrid with a combo box.
> The Data Grid is bound to the "OrderDetails" Table.
> The Combo Box is bound to the "Locations" Data Table.
>
> When I set a value (ie a Location) in the DataGrid using the combo box, it
> is setting the selected location for that record (Order Details Line )
only.
> It is not affecting the other records (Rows) in the data Grid or in the
> underlying Data Table ("OrderDetails")!!
>
> I want to know if I can set the bound DataView to filter for the value
> within the row rather than setting it as a column style.
>
> Or is there some other way to achieve this result.
>
> Say the datagrid is displaying records filtered for Order No 12345678 and
it
> has 10 lines.
>
> Some of Line 3 might have arrived so the User has to accept say 20 boxes
and
> allocates them to location A20.
> He selects row with Line: 3, Item: AA12345, Description: Blue Plastic,
> Units: Boxes, Expected: 50, Received:
> 5,...........................................................Qty Accepted:
> [20], Location: [A20]
>
> He entered the value 20 and selects the location 'A20' using the combo
box.
>
> Doug
>
> "Ken Tucker [MVP]" <vb2ae@bellsouth.net> wrote in message
> news:OXO6y$fwEHA.1260@TK2MSFTNGP12.phx.gbl...
> > Hi,
> >
> > Say you have 50 rows in that column there is only one combobox
> that
> > is displayed when a cell in the column goes into edit mode. If you bind
> the
> > combobox you will wind up changing values in rows that arent being
edited.
> > So what you need to do is just before the combobox is displayed you need
> to
> > clear the list and add the filtered items.
> >
> >
> > Ken
> > ----------------
> > "Doug Bell" <dug@bigpond> wrote in message
> > news:uOO1XRfwEHA.3276@TK2MSFTNGP15.phx.gbl...
> > Hi Ken,
> > I am not following.
> >
> > The Data Grid is bound to a Data View, "OrderDetails" filtered for a
> > particular OrderNo
> >
> > The combo box is bounnd to a Data View, "Locations" filtered currently
to
> > Locations for a selected Facility.
> >
> > The Combo Box is to assign a Location to an Order Detail Line.
> >
> > The Order Detail Line has a field, Warehouse already assigned to it.
> >
> > What I want to do is to filter the list of Locations in the combo box to
> > Locations within the particular Warehouse (on the OrderDetail line) as
> > opposed to the current filter that is for the whole Facility.
> >
> > I can not work out how to do that as currently I am binding the
Locations
> > data to the combo box as part of a custom GridTextBoxStyle set up.
> >
> > Thanks Doug
> >
> > "Ken Tucker [MVP]" <vb2ae@bellsouth.net> wrote in message
> > news:eplCkeUwEHA.356@TK2MSFTNGP10.phx.gbl...
> > > Hi,
> > >
> > > There is only one combobox for the column that is shown on the
> row
> > > that is being edited. You should add each item to the combobox
> manually.
> > > If you bind the data you will wind up changing the values in multiple
> > rows.
> > >
> > > Ken
> > > -----------------------
> > > "Doug Bell" <dug@bigpond> wrote in message
> > > news:%23QpGuxRwEHA.356@TK2MSFTNGP10.phx.gbl...
> > > Hi
> > > I have a datagrid with a combo box,
> > > I need to populate the combo with data dependant on the record value.
> > > eg for record 1, field Warehouse = 2R so combo would allow selection
of
> > > locations valid for 2R
> > > record 2 has Warehouse = 2M so combo on that row has a selection of
> > > locations valid for 2M
> > >
> > > I can set the combo datasource but can't see how to set it on a row by
> row
> > > basis.
> > >
> > > Can someone help.
> > >
> > > Thanks
> > >
> > > Doug
> > >
> > >
> > >
> >
> >
> >
>
>
- Next message: Ken Tucker [MVP]: "Re: Problems with SQL Statement"
- Previous message: james: "Problems with SQL Statement"
- In reply to: Doug Bell: "Re: datagrid combobox question"
- Next in thread: Cor Ligthert: "Re: datagrid combobox question"
- Reply: Cor Ligthert: "Re: datagrid combobox question"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|