It appears you have not yet registered with DEVPPL. To register please click here... (it's fast, easy and free!)

Forum

Log In Sponsors
Board index Programming Visual Basic Forum

Project Help

Moderator: dafunkymunky

Project Help

Postby wolves on Sun Apr 17, 2005 9:08 pm

Im having trouble with some coding for a program of mine. Around 80% of the project works but its the last few bits that i need help with.

Its probbaly best if i say what the problems are:

1) Im having trouble removing costs for items which have been removed in a list box (item cost reducted from current totals)

2) Im having trouble doing a running cost in a textbox (which is kinda linked to point 1)

3) Searching, editing and adding items to an array.

i'd be greatful if you could give me help. I will be gladly to post coding to help you.
wolves
 
Posts: 2
Joined: Sun Apr 17, 2005 7:22 pm

Postby Phate on Sun Apr 17, 2005 9:15 pm

First, Welcome to DEVPPL :)

Second, I think it would be helpfull if you posted the code
Web-Developing since '03
Image
User avatar
Phate
500+ Club
 
Posts: 826
Joined: Sun Nov 21, 2004 4:12 am
Location: 127.0.0.1

Postby wolves on Mon Apr 18, 2005 6:02 pm

hi ya, thanks for the warm welcome :)

Ill explain the problem in detail. On my command button once it is clicked it sends a service name into a list box and it also populates the other cost boxes (text boxes.) they all add correclty but when removing the items from the list box the costs do not go down.

This is the coding for the entering the service into the lsit box

Dim item As String
item = CmbServiceName.Text
Lstservices.AddItem item
labourcost = labourcost + Val(Mid(TxtLabCost1.Text, 2, Len(TxtLabCost1.Text) - 1))
materialcost = materialcost + Val(Mid(TxtMatCost1.Text, 2, Len(TxtMatCost1.Text) - 1))
TxtLabcost2.Text = Format(labourcost, "Currency")
TxtMatCost2.Text = Format(materialcost, "currency")
TxtTotal.Text = Format(labourcost + materialcost, "currency")

This is for removing the items in the list box

Private Sub CmdRemove_Click()
Dim listitem As Integer
listitem = Lstservices.ListIndex
Lstservices.RemoveItem listitem
End Sub

Have you any ideas?
wolves
 
Posts: 2
Joined: Sun Apr 17, 2005 7:22 pm

Postby dragul on Wed Apr 20, 2005 8:18 pm

Heya, i recently done a program with similar features. you can download the code from here:
http://www.studionet.uk7.net/media/apps/Code.zip
Hope you can extract the code you want from here.
dragul
 
Posts: 16
Joined: Wed Apr 20, 2005 7:54 pm
Location: Abergavenny, Wales, UK

Postby jeranio on Thu Sep 20, 2007 6:44 pm

Thanks so much for someone who posted the format currency line.
I was struggling for days now to show currency in my project.

Millions of Thanks
jeranio
 
Posts: 4
Joined: Thu Sep 20, 2007 6:16 pm


Who is online

Users browsing this forum: No registered users and 4 guests