Wernon Posted January 24, 2019 Report Share Posted January 24, 2019 Hi, I want to create a converter from decimal to HEX format. All the values are saved in the table. So the form should take the decimal number from the table field 1, convert and save the HEX value to field 2. I did not find any SQL solution. I would appreciate any ideas regarding the solution. Quote Link to comment Share on other sites More sharing options...
0 George43 Posted January 24, 2019 Report Share Posted January 24, 2019 I had this case and I just used single update form as Data Page. I Used "NumberNormal" as column name i should to convert. Added another column with name HexNum. After that i added simple HTML block in the bottom of Update Data Page and put this snippet of code. <script type="text/javascript"> document.addEventListener('DataPageReady', function (event) { var normal = Number(document.querySelector("#EditRecordNumberNormal").value); hexString = normal.toString(16); if (hexString.length % 2) { hexString = '0' + hexString; } document.querySelector("#EditRecordHexNum").value = hexString; }); </script> Quote Link to comment Share on other sites More sharing options...
Question
Wernon
Hi,
I want to create a converter from decimal to HEX format. All the values are saved in the table.
So the form should take the decimal number from the table field 1, convert and save the HEX value to field 2.
I did not find any SQL solution.
I would appreciate any ideas regarding the solution.
Link to comment
Share on other sites
1 answer to this question
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.
Note: Your post will require moderator approval before it will be visible.