Skip to Content
avatar image
Former Member

Retreive values from Business One screen

Hey All,

Can any experts give me some feedback on the best methods for retreiving from values from the Business One client screen through the UI? I am looking for best practices and methods when getting this information in your code.

I am have tried a few different ways and when we are dealing with large numbers of line items they all seem slow. I normally just get the com object and retrieve the property for the value.

I do not always freeze the screen when doing this. Should I? I have seen some postings where people have said this is faster which doesn't make sense to me.

Also I have seen examples where people use the datasources to retreive info. How does this work if the user has changed the value on the screen? Does the dbdatasource still contain the most recent value?

Any feedback or examples would be greatly appreciated.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Jul 12, 2006 at 10:04 AM

    Hi Curtis,

    The DbDataSources are not actualized if you change something in the screen until you press Update/Add...

    The way to read the datas depends on what you need to do: You need to read after creation or update, or you need to made a calculation while the user is filling a matrix,...

    Reading a matrix with a big number of lines is not very performant, if you only need to read some specific values you can maybe read only them or read them when the cell is validated for example. The best is to use DbDataSources or read the object from the database using DI API, but if you have to do something before you are forced to do otherwise.

    Hope it helps

    Trinidad.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi Curtis,

      I read controls values directly and they don't flash as they do when placed in a matrix. So I think you can avoid the freeze in this case.