具有一般功能的发票申请
大家好,
我正在为我的一个朋友开发一个简单的发票应用程序.由于我还没有做过这类事情,所以我想向大家提出我的解决方案,并寻求一些反馈.
该应用程序主要包含,
1.)添加项目并计算总金额(将来可能会考虑折扣,税项等)
2.)为客户打印发票.
我至少会忘记第二点.
谈到第一个,我考虑使用ListView.现在说我想处理,
1.)物品代码
2.)说明
3.)单价
4.)数量
5.)折扣
6.)金额
最后是所有已添加项目的总金额.所以我想允许某些字段对用户是可编辑的,例如项目代码.假设用户输入商品代码,然后按Enter或Tab键.从存储库中逻辑描述和选择单价,并填写相关字段.然后,鼠标应将焦点放在数量"上,依此类推.希望这是最好的方法.
我现在要搜索的是如何使行在s listview中可编辑.我可以采取的任何方法.
我对Label Edit属性感到厌倦.一旦在事件上启用它,我就可以选择编辑模式.但是不确定这种方法的优缺点.
如果你们能对我发表评论,我会非常感激.
Hi all,
I am looking a develop a simple invoice application for one of my friends. Since I haven''t done this kind of stuff, I like to propose my solution to you all, and looking some feedback.
Mainly this application contains,
1.) adding items and calculate the total amount (may consider about discounts, tax, etc... in future)
2.) print the invoice for the customer.
I''ll forget the second point at the min.
Talking about the first, I think of using a ListView. Now say I want to deals with,
1.) Item code
2.) Description
3.) Unit Price
4.) Quantity
5.) Discount
6.) Amount
and at the end total amount for all the items added. So I want to allow some of the fields are editable to the user such as Item code. Say user enter the item code and press enter or the tab key. Logically description and unit price pick from repository and fill the relevant fields. Then mouse should focus on Quantity and so on. Hope that is the best approach.
The thing I am searching right now is how to make a row is editable in s listview. Any approach I can take.
I tired with Label Edit property. Once it is enabled on an event I can pick the edit mode. But not sure about pros and cons about that approach.
If you guys could comment on me really appreciate.
使用 ^ ],它提供了更多功能.您还可以通过此控件使用自动数据绑定,这样可以更轻松地使视图和后备存储保持同步.
You would probably be better using a DataGridView[^], which offers much greater functionality. You can also use automatic data binding with this control which makes it easier to keep your view and backing store in sync.