Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to add a menu item with Weight and its price using C# extensibility code

Status
Not open for further replies.

Vikram Singh

Programmer
Jan 3, 2018
39
KW
Hello experts,

How can I Insert/add a menu item to an open check with ItemWeight and PriceOverride using
C# extensibility code in Simphony Micros

Thank You,
 
did you find the solution for it? I have the similar requirement?
 
The item will need a menu item class with Option 15 set then you can use the following code which constructs it as a macro:

Code:
List<OpsCommand> opsCommands = new List<OpsCommand>();
opsCommands.Add(new OpsCommand(OpsCommandType.MenuItem) { Number = 990010022 }); // Menu item object number
opsCommands.Add(new OpsCommand(OpsCommandType.AsciiData) { Text = "120" }); // Item Weight
opsCommands.Add(new OpsCommand(OpsCommandType.EnterKey));
opsCommands.Add(new OpsCommand(OpsCommandType.PriceOverride) { Text = "3.00" }); // New Price

OpsCommand opsCommand = new OpsCommand(OpsCommandType.Macro);
opsCommand.Data = opsCommands;
var cmdResult = _opscontext.ProcessCommand(opsCommand);

If your item is set as an open item rather than a price per kg it would be a little different.
 


Wow,
Thank you very much, my friend. Sorry for the delayed response.
It's working fine once again thank you sab0tage
this works nicely. If you can tell me how I can do the same with open items with Weight it will be a great help
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top