Dear Experts,
In LS Retail> POS Client I wanted to have Description2 field as for some items the the description was so long that i could not fit into Descrtiption 1 field.
However, I managed to bring the Description 2 field in POS client, but particularly only that field is not highlighted in blue color like other fields.
Could you kindly let me know that what could be the possible reason for this? Why only Desc2 field is not highlighted in blue when i am scanning the item.
Attached is the snapshot for clarification. if you will notice, the text "Million Dollar Pack" in Desc2 field is not highlighted with blue color.
Thanks & Regards,
Fahd
0
Comments
Thanks for the reply, No i did not add the code.
Can you please tell me how can i add that code?
Thanks & Regards,
Fahd
Yes i know the On Format Trigger and i have found it.
:thumbsup:
I am trying to add the code but i can't make it.
In the existing Description 1 field i found this code under the ONFORMAT trigger.
SmallDescription - OnFormat(VAR Text : Text[1024];)
GetCurrLineColor();
IF ("Parent Line" <> 0) AND ("Line No." <> "Parent Line") THEN
IF COPYSTR(Text,1,1) <> '>' THEN Text := '>' + Text;
CurrForm.SmallDescription.UPDATEFORECOLOR(ForeColor[CurrColor]);
CurrForm.SmallDescription.UPDATEFONTBOLD(Bold[CurrColor]);
I have copied the same to my desc2 field's ONFORMAT trigger and i replaced small description to desc2 which is my variable and field name.
But i can't make it, Kindly guide me.
CurrForm.SmallDescription.UPDATEFORECOLOR(ForeColor[Cu
SmallDescription in this code line refers to the Name property of the control, not to the variable or field name.
FD Consulting
Ok, my field name in the "Pos Trans. Line" table is "desc2".
I modified the record for this field under the triggger OnFormat and following is the code.
desc2 - OnFormat(VAR Text : Text[1024];)
CurrForm.desc2.UPDATEFORECOLOR(ForeColor[CurrColor]);
But now when i am scanning the item following error is coming.
"The Dynamic Property 'ColorSet' cannoot be changed in this content.
You tried to change 'Colorset' the on the TexBox named 'desc2'
The code above can only be run in the OnFormat Trigger of the Control with the Name "desc2". NAV will give the error you received if you try to set the forecolor of Field "desc2" in the OnFormat Trigger of another control (e.g. "desc 2").
Check the Name property of the control where you have placed your code. Possibly you have 2 controls with the same Name and NAV references the wrong one.
FD Consulting