Encerrado

Create one MS Access form with tree control

Create one MS Access form which displays a hierarchy of employees from Northwind Traders which permits drag and drop reorganization of hierarchy, changing the reporting relationships between employees.

This form must use the exontrol's ExGrid activeX control rather than the MS TreeView control.? ExGrid allows the first column to display a hierarchy like TreeView and allows other columns to display information about the value displayed in the grid.

Here's a simple example:

Employee? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Job Title? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Fax number

John? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? President? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? 111-111-1111

-- Mary? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Vice President Marketing? ? 222-222-2222

---- Louise? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Secretary? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? 333-333-3333

-- Gary? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Vice President Logistics? ? ? ? 444-444-4444

---- Tom? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Production manager? ? ? ? ? ? ? ? ? 555-555-5555

---- Robert? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Shipping manager? ? ? ? ? ? ? ? ? ? ? ? 666-666-6666

## Deliverables

This project is to create a one Microsoft Access form with a tree that displays employees in the Northwind Trader employees table in a TreeView-like hierarchy with drag and drop capability to reassign employees.

?

MS Note 167309 “Sample Procedure to Fill a TreeView Control Recursively?? illustrates how to use the superior/subordinate relationships of employees in the Northwind Traders database to do this with MSTreeView 5.0 SP2.? The attached database has a working illustration of this note..

?

My project is to create one form, but replace the TreeView 5.0 SP2 with an activeX control ExGrid from exontrol.com.? The download can be found at <[url removed, login to view]>.

?

Online help for ExGrid includes sample code for VB, VBA, FoxPro, C++, etc. and is located at <[url removed, login to view]>

?

This control is available for a free, unlimited evaluation period and also supports drag and drop like the TreeView.

?

It is necessary to download this control and add it to the list of activeX controls that can be used by MS Access.

?

Exontrol technical support states that ExGrid will support drag and drop as shown below:

?

'===================================================

Back to the issue, you can have the drag and drop exactly as in the Microsoft TreeView control with the link you provided.

?

Shortly, you need:

?

1. Set the OLEDropMode = 1

2. Handle the OLEStartDrag event amd set the AllowedEffects parameter on 2 and call the [url removed, login to view] with some data to be dragged

3. Handle the OLEDragDrop event.

?

A simple sample will be:

?

Private Sub Form_Load()

? ? ? [url removed, login to view] = exOLEDropManual

End Sub

‘----------------------------------------------------------------------

Private Sub Grid1_OLEDragDrop(ByVal Data As [url removed, login to view], Effect As Long, ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)

? ? ? Dim hI As HITEM

? ? ? hI = CLng([url removed, login to view](exCFText))

? ? ? If (hI <> 0) Then

? ? ? ? ? ? ? With Grid1

? ? ? ? ? ? ? ? ? ? ? Dim c As Long, hit As HitTestInfoEnum

? ? ? ? ? ? ? ? ? ? ? Dim h As Long

? ? ? ? ? ? ? ? ? ? ? h = .ItemFromPoint(-1, -1, c, hit)

? ? ? ? ? ? ? ? ? ? ? If (h <> 0) Then

? ? ? ? ? ? ? ? ? ? ? ? ? ? ? .BeginUpdate

? ? ? ? ? ? ? ? ? ? ? ? ? ? ? With .Items

? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? .SetParent hI, h

? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? .ExpandItem(h) = True

? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? .SelectItem(hI) = True

? ? ? ? ? ? ? ? ? ? ? ? ? ? ? End With

? ? ? ? ? ? ? ? ? ? ? ? ? ? ? .EndUpdate

? ? ? ? ? ? ? ? ? ? ? End If

? ? ? ? ? ? ? End With

? ? ? End If? ? ?

End Sub

‘---------------------------------------------------------------------

Private Sub Grid1_OLEStartDrag(ByVal Data As [url removed, login to view], AllowedEffects As Long)

? ? ? With Grid1

? ? ? ? ? ? ? Dim c As Long, hit As HitTestInfoEnum

? ? ? ? ? ? ? Dim h As Long

? ? ? ? ? ? ? h = .ItemFromPoint(-1, -1, c, hit)

? ? ? ? ? ? ? If (h <> 0) Then

? ? ? ? ? ? ? ? ? ? ? AllowedEffects = 2

? ? ? ? ? ? ? ? ? ? ? [url removed, login to view] h, exCFText

? ? ? ? ? ? ? End If

? ? ? End With

End Sub

‘---------------------------------------------------------------------

This sample changes at runtime the parent for the dragged item with the one that hovers the cursor. The sample can be complicated so it can change the position of item, and so on.

'====================================================

Habilidades: Engenharia, Microsoft, Microsoft Access, Gestão de projetos, Arquitetura de software, Teste de Software, Visual Basic para Apps, Área de trabalho do Windows

Ver mais: form tree control access, microsoft access activex drag drop treeview, sample tree form access, vice com, technical support job online, support illustration, shift manager, setdata, secretary x, secretary 2, recursively, project manager job online, project manager download free, online technical support job, online project manager job, online job trader, online job for vba ms access, online illustration job, note value tree, ms project online free, ms access online, microsoft support number, microsoft access job, marketing job title, marketing illustration

Acerca do Empregador:
( 37 comentários ) Pittsburgh, United States

ID do Projeto: #3606419

5 freelancers are bidding on average $39 for this job

Prashantskin

See private message.

$34 USD in 10 dias
(510 Comentários)
7.0
brightsolnslx

See private message.

$42.5 USD in 10 dias
(294 Comentários)
6.3
gajjarsystemsvw

See private message.

$42.5 USD in 10 dias
(25 Comentários)
4.7
ashmantri

See private message.

$34 USD in 10 dias
(2 Comentários)
0.6
ashkgwithusl

See private message.

$42.5 USD in 10 dias
(1 Comentário)
0.0