Skip to Content
0
Former Member
Jul 05, 2012 at 12:09 PM

Journel entry through the program...

21 Views

Hi.. See the image..

one edit box value is there and one button is there

my requirement is if any body press the button that particualr value should be added to the particular account.

i had all ready added one account in journal entry.

but it wont work.. is there any reason

I had used this code..

Try

If (pVal.BeforeAction = True And pVal.FormUID = "TT" And pVal.EventType = SAPbouiCOM.BoEventTypes.et_ITEM_PRESSED) Then

If (pVal.ItemUID = "53") Then

oform = sbo_app.Forms.Item("TT")

Dim ojv As SAPbobsCOM.JournalVouchers

ojv = ocompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oJournalVouchers)

'ojv.JournalEntries.Lines.SetCurrentLine(0)

If (oform.Items.Item("25").Specific.value > 0) Then

ojv.JournalEntries.Lines.AccountCode = "1134"

Dim d As Integer = oform.Items.Item("25").Specific.value

ojv.JournalEntries.Lines.Debit = d

ojv.JournalEntries.Lines.Add()

End If

ojv.JournalEntries.Add()

End If

End If

Catch ex As Exception

sbo_app.MessageBox(ex.Message)

End Try

Attachments

jv.JPG (92.5 kB)