herculanojs Posted May 11, 2016 Share Posted May 11, 2016 I'm uam difficulty. When I create dynamic DBGrid if closing the dataset and reopen again. The column definitions created in runtime are lost and are shown all dataset columns without any previous attributes. This is a bug? Fields in Dataset (ID,Nome, etc); with DBGrid.Columns.Add do begin FieldName := 'id'; Title.Caption := 'ID'; Width := 80; end; with DBGrid.Columns.Add do begin FieldName := 'nome'; Title.Caption := 'Nome'; Width := 80; end; After closing and opening all columns are shown Quote Link to comment Share on other sites More sharing options...
Sherzod Posted May 11, 2016 Share Posted May 11, 2016 Hi, Pls, can you make a small test case ?! Best regards. Quote Link to comment Share on other sites More sharing options...
herculanojs Posted May 11, 2016 Author Share Posted May 11, 2016 I found the problem. If the dataset is opened before dynamically create the grid, the DBGrid assumes the settings of the first opening of the dataset, ignoring subsequent settings. first created the dbgrid and fixed wireless problem Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.