MS Access: custom control built in another language

The entire basis of this project relies on the ability to retrieve the LB index when the mouse is moved over the row. That is derrived from the GetListIndex function, thus the GetLRBH function, thus the Wizhooks function.

The UpdateRecordset failed for that exact reason - the index was retrieved incorrectly - then passed to updaterecordset and failed, hence error 3021. UpdateRecordset (3021) and 6015 are NOT separate issues like you are suggesting. They work 100% of the time when the index is retrieved correctly. They parallel each-other in how they work. The only explanation would be GetListIndex code, or Wizhooks code.

So, do you have evidence to suggest it is NOT wizhooks-related? That could be solved pretty quickly if you would step through the code and see what incorrect indicies are returning when 6015 occurs, which somehow does not occur for me as i've shown in multiple videos. - further suggesting that it is highly related to Wizhooks.
 
The entire basis of this project relies on the ability to retrieve the LB index when the mouse is moved over the row. That is derrived from the GetListIndex function, thus the GetLRBH function, thus the Wizhooks function.

Your logic is flawed. Just because A depends on B which itself depends on C and that ultimately on D, it doesn't mean that an issue in A is caused by D.
Or to use an analogy, pigs eat acorns, humans eat pigs but that doesn't mean we can eat acorns.

The UpdateRecordset failed for that exact reason - the index was retrieved incorrectly - then passed to updaterecordset and failed, hence error 3021. UpdateRecordset (3021) and 6015 are NOT separate issues like you are suggesting. They work 100% of the time when the index is retrieved correctly. They parallel each-other in how they work. The only explanation would be GetListIndex code, or Wizhooks code.
So, do you have evidence to suggest it is NOT wizhooks-related? That could be solved pretty quickly if you would step through the code and see what incorrect indicies are returning when 6015 occurs, which somehow does not occur for me as i've shown in multiple videos. - further suggesting that it is highly related to Wizhooks.

I didn't suggest the errors were unrelated. As with my original app, if the mouse moves below the last record in the listbox there is no valid list index. That will cause an error unless it is handled. Just as I did but in a different way in my original app.

As previously stated you said you had experienced both errors...but not consistently
Tera gave you the answers to your questions back in post #70 or thereabouts

Now try a different test with my latest version or with your v4.0
Drag the last record in the list downwards and let go. Notice what happens.

I had intended not to get involved with this thread. I've already spent longer on it than I intended. Its now working reasonably well. However, unless someone can find a solution for the scrolling issue I don't intend to spend any more time on this
 
Last edited:
I find it peculiar that v4.0 and v4.1 do not return any errors for me. There are two separates issues here. One is 6015 that allegedly occurs when the listbox has no scrolls bars and item is dragged from top to bottom.

The second issue in question has to do when scrollbars are present which I still have not gotten an error, just unusual behavior. But that is not a topic that I am personally concerned with.

Problem 1 has occured for me maybe 3 times ever. Which is highly peculiar. I cannot test any hypothesis because the problem never occurs for me.

I have not tried dropping the item "outside" the perimeter of the listbox, to see what the behavior is, but I would be inclined to believe nothing will happen.

The only other test I can do is running a VBA Decompile tool on the project and retry to see if something is somehow hanging in cache allowing my system to be immune.

Other than that, I'm fine with not investigating any further because like I said, I have no error, and cannot solve a problem I am not having.
 
1 didn't suggest dropping an item outside the listbox perimeter.
Just move it down into the empty space and let go.
No error occurs but you may not expect what does happen

EDIT
Just realised belatedly that this listbox doesn't have column headers. There are labels above the list.
Whilst that's fine and I often do the same, the code would need modifying to be used in a standard listbox with column headers. As it stands, the wrong record gets dragged currently
 
Last edited:

Users who are viewing this thread

Back
Top Bottom