Jump to content

DateTimePicker Formatting issue via DBGrid


pro_imaj

Recommended Posts

Hi,

On the MSSQL side, I keep a field of Date type, this field is data entry via DBGrid.

This is how the DateTimePickert to which the editor is connected on the DBGrid

Very interesting data is coming. I expect it to behave like this when both displaying the Grdi data and entering the data. DD/MM/YYYY

These are the corresponding server module Create event PFmtSettings.ShortDateFormat := 'dd/mm/yyyy'; I added it but nothing changed.

What is the correct solution?

* If I format the date on the SQL side, it does not enter the editing mode on the Grid this time. Datetimepicture does not detect it as a date.

  • Like 1
Link to comment
Share on other sites

On 10/5/2022 at 1:50 PM, pro_imaj said:

Hi,

On the MSSQL side, I keep a field of Date type, this field is data entry via DBGrid.

This is how the DateTimePickert to which the editor is connected on the DBGrid

Very interesting data is coming. I expect it to behave like this when both displaying the Grdi data and entering the data. DD/MM/YYYY

These are the corresponding server module Create event PFmtSettings.ShortDateFormat := 'dd/mm/yyyy'; I added it but nothing changed.

What is the correct solution?

* If I format the date on the SQL side, it does not enter the editing mode on the Grid this time. Datetimepicture does not detect it as a date.

I can't fix this problem, what should I do?

Link to comment
Share on other sites

  • 2 weeks later...
6 hours ago, pro_imaj said:

@Hayri ASLAN When I translate the field type as text, it gets fixed, but when the field type is date on the mssql side, the following error occurs.

Which user are you using for hyperservice? 

Can you make sure you are using a user with correct regional settings?

image.png.5ddbcec1073155710fc1f6d2e6ba020c.png

Please make sure you applied your regional settings to Welcome Screen and System Accounts.

image.png.a87ed807db2180083b2cd09f92f57798.pngimage.png.60d64d29e90271dbe19b88c749cd45e2.png

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...