Create a jsDatagrid control dynamically
Hi An
Thank you for your response !
Yes thats set earlier in the method but I found the solution, what I needed
to do is before anything else is to toggle the $userdefined flag like this:
Do iGridReference.$userdefined.$assign(kFalse)
Do iGridReference.$userdefined.$assign(kTrue)
I’m not 100% sure why but but for now I’m happy it works 🙂
Best Regards
Jan
2017-11-02 19:32 GMT+01:00 An.bayens@justsoftware.be < an.bayens@justsoftware.be>:
> Hi Jan,
>
> Do you also do a $dataname.$assign?
>
> Groeten
> An Bayens
>
> > Op 2 nov. 2017 om 18:30 heeft Jan Eskilsson <janeskil1525@gmail.com>
> het volgende geschreven:
> >
> > Hi All
> >
> > Studio 8.0.3.2
> >
> > I try to define a jsData grid control dynamically but I don’t seem to
> have
> > any luck in making this work so I wonder anyone has done this ?
> >
> >
> > What I try is to set the following properties:
> >
> >
> > Do iGridReference.$designcols.$assign(iCompanyGridFields.$linecount())
> > Returns FlagOk
> >
> > For iCompanyGridFields.$line from 1 to iCompanyGridFields.$linecount()
> step
> > 1
> >
> > Do iGridReference.$currentcolumn.$assign(iCompanyGridFields.SortOrder)
> > Returns FlagOk
> >
> > Do iGridReference.$columndatacol.$assign(iCompanyGridFields. FieldName)
> > Returns FlagOk
> >
> > Do iGridReference.$columnwidth.$assign(iCompanyGridFields.ColWidth)
> Returns
> > FlagOk
> >
> > Calculate GridHeader as con(GridHeader,iCompanyGridFields.FieldName)
> >
> > If iCompanyGridFields.$line()<>iCompanyGridFields.$linecount()
> >
> > Calculate GridHeader as con(GridHeader,”,”)
> >
> > End If
> >
> > End For
> >
> > Do iGridReference.$columnnames.$assign(GridHeader)
> >
> >
> >
> > What i get is a blanc screen 🙁
> >
> >
> > Do anyone know if I need to set anything else or is it not possible ?
> >
> >
> >
> > T I A
> >
> >
> > Best Rgeards
> >
> > Jan
> > —
> > Titles mean nothing. The one with a servant’s heart is the leader.
> >
> > Please consider the environment before you print this email.
> >
> > (1) The contents of this transmission are privileged and confidential and
> > intended solely for the use of the addressee. Any disclosure,
> distribution
> > or copying of the contents, other than by the addressee, is strictly
> > prohibited. If you receive this transmission in error, please notify us
> > immediately and destroy the material received.
> > (2) All incoming and outgoing emails and any attachments are subjected
> to a
> > virus scanner and are believed to be free of any virus, or any other
> defect
> > which might affect any computer or IT system into which they are received
> > and opened. Therefore, it is the responsibility of the recipient to
> ensure
> > that they are virus free and no responsibility is accepted by Jan
> Eskilsson
> > for any loss or damage arising in any way from receipt or use thereof.
> > _____________________________________________________________
> > Manage your list subscriptions at lists.omnis-dev.com
>
> _____________________________________________________________
> Manage your list subscriptions at lists.omnis-dev.com
>
—
Titles mean nothing. The one with a servant’s heart is the leader.
Please consider the environment before you print this email.
(1) The contents of this transmission are privileged and confidential and
intended solely for the use of the addressee. Any disclosure, distribution
or copying of the contents, other than by the addressee, is strictly
prohibited. If you receive this transmission in error, please notify us
immediately and destroy the material received.
(2) All incoming and outgoing emails and any attachments are subjected to a
virus scanner and are believed to be free of any virus, or any other defect
which might affect any computer or IT system into which they are received
and opened. Therefore, it is the responsibility of the recipient to ensure
that they are virus free and no responsibility is accepted by Jan Eskilsson
for any loss or damage arising in any way from receipt or use thereof.
_____________________________________________________________
Manage your list subscriptions at lists.omnis-dev.com