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

can someone fiux this code for me

Moderator: dafunkymunky

can someone fiux this code for me

Postby linoukus on Fri Nov 17, 2006 8:00 pm

ok i know this code is wrong because what i want it to do is beond me coding capablity,

the purspose of the code is take some data and paste it in the right place in excel.

Private Sub cmdFinish_Click()
Dim strDepartment As String
Dim strSheet As String
Dim strDeliver As String
Dim strDate As String
Dim strTest As String
Dim intTest As Integer
Dim intQuanity As Integer
Dim strSheet As String

Sheets("Sheet1").Select
strDeliver = txtDeliver
strDate = txtDate
Range("H2").Value = strDeliver
Range("I2").Value = strDate
intTest = 3
strTest = "D" + intTest
intQuanity = Range(strTest).Value
strDepartment = Range("H2").Value
strMonth = Range("J2").Value
strSheet = strDepartment + strMonth

Do Until intQuanity = 0
intTest = intTest + 1
Loop

Range("A2:F2,H2,I2").Copy
Sheets(strMonth).Select
Range("strTest").Selecth
ActiveSheet.Paste
End Sub
if you could help me i would be very grateful
linoukus
 
Posts: 0
Joined: Fri Nov 17, 2006 7:54 pm

Who is online

Users browsing this forum: No registered users and 7 guests