Active Query Builder support area

When using CustomExpressionBuilder add a property that make the expression/criteria columns read only

Avatar
  • updated
  • Completed

Arrrggh :) This doesn't quite work but I though I would post it anyway as it might provoke a thought

In conjunction with my other two requests about editing SQL output columns with QT and exposing a cell reference in CustomExpressionBuilder so you know exactly which cell the ellipsis was clicked on.

Both of these requests could be 'avoided' if when using the CustomExpressionBuilder the Expression, Criteria and Or cells were all made 'read-only'

By that I mean you can click the ellipsis to launch a custom dialog to do what you like in, even provide a free type text box if one wishes but when the text is returned to the cell, if it is read only, You then know when the user next clicks on the ellipsis the OldExpression value will be as you set it i.e. they can't change it, the custom dialog is in total control

It doesn't get around one really needs to store some metadata to save having to 'reverse engineer' the OldExpression string to populate the custom dialog ..... but at least you would be in control of what you were reverse engineering

Thanks for listening !

Avatar
Andrew Kennard

I have just downloaded v1.26.24 and this appears to now be fixed in Dataflex.

Thanks VERY much!

If I find another combination that does not work I will let you know but after some quick testing things seem to be much better

Avatar
Andrey Zavyalov, PM

We are preparing the new build. It will be available this week.

Avatar
Andrew Kennard

Have you managed to see the problem above in VB when the mouse is moved over the table ?

Thanks

Avatar
Andrew Kennard

I don;t quite see this same behaviour in Dataflex (nothing has changed still the same problem) but hopefully if you fix this highlight problem in the VB version it will fix it in Dataflex too

Avatar
Andrew Kennard

Hi

I assume this is 1.26.23 ie there is not a newer version

I am not seeing this working properly .... although I think I have just found when it fails

Having clicked on the "..." and then close the dialog/form if you move the mouse across the table in the design area you will see the cell in the grid go to a full blue cell highlight

If you don't move the mouse across the table then you can click on the "..." again fine

For reference here is my very simple test code

Thanks

Public Class Form1


Private Sub Form1_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
AxActiveQueryBuilderX1.LoginPrompt = False
AxActiveQueryBuilderX1.SelectListOptions.UseCustomExpressionBuilder = True
AxActiveQueryBuilderX1.ConnectionString = "Provider=SQLOLEDB; ..."
AxActiveQueryBuilderX1.Connected = True
End Sub


Private Sub AxActiveQueryBuilderX1_OnCustomExpressionBuilder(sender As System.Object, e As AxActiveQueryBuilderXControls.IActiveQueryBuilderXEvents_OnCustomExpressionBuilderEvent) Handles AxActiveQueryBuilderX1.OnCustomExpressionBuilder
Dim expr As String
Dim i As Int32

'expr = InputBox("Enter expression", "Expression Builder ActiveX", e.aParams.OldExpression)
'If expr <> e.aParams.OldExpression Then e.aParams.NewExpression = expr
'i = e.aParams.CompletionsList.Count

Form2.ShowDialog()
End Sub
End Class
Avatar
Andrey Zavyalov, PM

Hi,

Yes, we've done the tests. VB.NET tests run fine now.

Avatar
Andrew Kennard

Any news on this one ?

Thanks

Avatar
Andrew Kennard

Thanks for your efforts but I'm afraid I'm not seeing a change to the behaviour in Dataflex

I also tried to remove the COM reference from the VB project properties and add it again but it gave me all sorts of errors some of which I have auto resolved but others I cannot as i'm not a VB programmer

Did you try the same VB test as me after making the change ?

Thanks

Avatar
Andrey Zavyalov, PM

Hi,

In the new version focus is changed after assignment of the NewExpression property. Please let us know if this solves the problem or not.

Avatar
Andrew Kennard

4. In fact a very quick VB test seems to show a similar result to Dataflex

Modal for is just a form with textbox and button

you will see the return behaviour is different to that of InputBox

Private Sub AxActiveQueryBuilderX1_OnCustomExpressionBuilder(sender As System.Object, e As AxActiveQueryBuilderXControls.IActiveQueryBuilderXEvents_OnCustomExpressionBuilderEvent) Handles AxActiveQueryBuilderX1.OnCustomExpressionBuilder

Dim expr As String
Dim i As Int32

'expr = InputBox("Enter expression", "Expression Builder ActiveX", e.aParams.OldExpression)
'If expr <> e.aParams.OldExpression Then e.aParams.NewExpression = expr
'i = e.aParams.CompletionsList.Count

modalform.Show()

End Sub