Text Lines SBO 2007

Hi people.
I'm trying to add text lines in a quotation via DI with 2007 SDK but my code doesn't work!
This is:
                                oOferta.SpecialLines.Add()
                                If mNumSpLinea > 0 Then
                                    oOferta.SpecialLines.SetCurrentLine(mNumSpLinea)
                                End If
                                oOferta.SpecialLines.LineType = SAPbobsCOM.BoDocSpecialLineType.dslt_Text
                                oOferta.SpecialLines.LineText = xHoja.Range(mCelDes).Value.ToString.Trim
                                oOferta.SpecialLines.AfterLineNumber = mNumLinea + mNumSpLinea
                                mNumSpLinea = mNumSpLinea + 1
nNumSpLinea is a text lines counter because with general lines counter (from quotation) doesn't work.
AfterLineNumber doesn't affect. Doesn't work with or without this
I change this code trying to work but I lost!
Any ideas???
Thanks in advance
Juli P.

Hi,
I have tested SpecialLines adding in a Quotation and it works fine. I'm testing with PL11.
You have to pay attention and for each SpecialLine to be added you need first to call
Qut.SpecialLines.Add()
If you don't add first the SpecialLine then it will give you errors or ignore the added lines.
Please check the SDK Help File, the following sample is there:
Sub AddSpecialLine()
        'Adding special line
        'Assume Qut is an existing Quotation Document Object
        Qut.SpecialLines.Add()
        'Setting the type of special line to be sub total
        Qut.SpecialLines.LineType = SAPbobsCOM.BoDocSpecialLineType.dslt_Subtotal
        'Setting the after line number
        'A number that says after which line the special line will appear
        Qut.SpecialLines.AfterLineNumber = 2
        'Check for errors
        lRetCode = Qut.Update()
        If lRetCode <> 0 Then
            oCompany.GetLastError(lErrCode, sErrMsg)
            MsgBox(lErrCode & " " & sErrMsg) ' Display error message
        Else
            MsgBox("Special Lines Added")
        End If
End Sub
Hope it helps
Trinidad.

Similar Messages

  • Add Text Lines SBO 2005

    Hi there, for a while I guess tha I have found my answer in a similar post, however this refers to SBO 2007, and I need to make this on SBO 2005, anyway ...
    I need to add text lines in a purchase order via DI, but I can't find how to make it
    Any ideas?
    Thanks in advance and best regards
    Aristoteles

    Wow, bad news for me Eddy anyway I appreciate really your quick answer.
    But, do you guess that is there another way to solve this without SpecialLines?
    Thanks again
    Aristoteles
    Edited by: Aristóteles Quintanar Ramos on Jan 30, 2008 2:04 PM

  • Document line with price zero in SBO 2007 A

    Hi All
    We have a DI API AddOn that occationally has to create a document line with the total price of zero.
    In SBO 2005 A we just set SBODocument.Lines.Price = 0, but that doesn't work in SBO 2007 A.
    In 2007A when we set SBODocument.Lines.Price = 0 it takes the price from the pricelist as though we had not entered a price at all. If we set SBODocument.Lines.Price to something else that zero it does correctly take the price we entered.
    We have tried to set SBODocument.Lines.UnitPrice or SBODocument.Lines.LineTotal to zero in stead but it gives the same result.
    Any help appriciated.
    Rgds
    Jesper Carstensen

    Sorry, my mistake.
    The solution WAS indeed to set SBODocument.Lines.UnitPrice = 0
    Rgds
    Jesper Carstensen

  • SBO 2007 PL06 - GetCompanyList fails

    Folks,
    I am not able to get the list of companies on SBO 2007. The following code fails with "Failed to connect to SBOCommon" error.
    try {
       SAPbobsCOM.Company c = new SAPbobsCOM.Company();
       c.Server = "Test17";
       c.DbServerType = SAPbobsCOM.BoDataServerTypes.dst_MSSQL2005;
       c.UseTrusted = "true";
       SAPbobsCOM.Recordset cl = c.GetCompanyList();
    } catch (Exception e) {
       Console.WriteLine(e.Message);
    Note that all other APIs work just fine. I am able to open connection to specific company and perform any programmatic operation. It is just that GetCompanyList fails.
    I am running this code on the machine where SBO server is installed. So there are no network issues.
    I have tried setting the server to "local," "(local)", "localhost", etc. Still no success.
    I also tried setting UseTrusted to false and specified DbUsername and DbPassword. Still no success. As far as I know, GetCompanyList always uses trusted connection and ignores usrename/password fields.
    Does anyone know what the problem could be?
    Thank you in advance for your help.
    Regards,
    Pradeep

    Hi
    pls try this code,
    oCompany = New SAPbobsCOM.Company
                If cmbServertype.Text = "SQL SERVER 2005" Then
                    oCompany.DbServerType = SAPbobsCOM.BoDataServerTypes.dst_MSSQL2005
                Else
                    oCompany.DbServerType = SAPbobsCOM.BoDataServerTypes.dst_MSSQL
                End If
                oCompany.Server = "Test"
                oCompany.language = SAPbobsCOM.BoSuppLangs.ln_English
                oCompany.DbUserName = "sa"
                oCompany.DbPassword = "SQL"
                 oRecordSet = Me.oCompany.GetCompanyList()
                Me.oCompany.GetLastError(lErrCode, sErrMsg)
                If lErrCode <> 0 Then
                    MsgBox(sErrMsg)
                    Exit Sub
                Else
    Msgbox("Connection Success")
    endif
    Regards
    Senthil Kumar

  • Text lines - won't copy from order to deliver to invoice.

    Our client has upgraded from 2007 to 8.8 pl 14
    When they copy from an order to deliver the text lines are just not copied.  Same applies from delivery to invoice.
    Has anyone else experienced this issue.
    Has anyone got any ideas as to how I can fix this.
    Thanks
    Jo

    Hi Jo,
    I tried that on PL 15 and it works fine for me. Is there, by any chance, a formatted search assigned to that field?
    Regards
    Sudatt

  • Text lines in the BW query variables screen

    Hi gurus.
    The bw users ask me to display some text lines in the BW query variables prompt.
    The text lines are saved in a custom table.
    The only idea that I've got is to use customer exit text variables and fill them in CMOD when I_step = 1.
    I don't like this solution (I should have more the 10 text lines and so I have to mantain more than 10 Text variables) but I can't find any other solution.
    Any new idea or solution?
    Is there in Bex enviroment a functionality (that I don't know) for doing somenthing like this ?
    Thanks fo any help.
    S.

    Hi,
    to resolve it you should create all the prompts in the BW query. You are using a query with 2 parameters and then a dynamic list of values. the dynamic list of values can only work after you entered the other values.
    Ingo

  • Sales Order Text Lines in SAP Query

    I have a requirement to output several text lines into a SAP query based around sales orders.
    I have included some code to read the details into my query and get no syntax errors, however the report gives a blank output for each of the text fields included, despite there definitely being some text with the specified attribute ID and text object in the table STXL.
    Where am I going wrong?
    Please find the coding below for one of the text field I'm trying to extract:
    TABLES:STXL.
    DATA:
        VBELN LIKE VBAP-VBELN,
        POSNR LIKE VBAP-POSNR,
        TDNAME LIKE STXL-TDNAME,
        MYLINE LIKE TLINE-TDLINE,
        ZE18_LINE(1200) TYPE C.
    DATA:BEGIN OF LINES OCCURS 0.
            INCLUDE STRUCTURE TLINE.
    DATA:END OF LINES.
    DATA:BEGIN OF MYHEADER.
            INCLUDE STRUCTURE THEAD.
    DATA:END OF MYHEADER.
    CLEAR TDNAME.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
      INPUT = VBAP-VBELN
    IMPORTING
      OUTPUT = VBELN.
      CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
      INPUT = VBAP-POSNR
    IMPORTING
      OUTPUT = POSNR.
      CONCATENATE VBELN POSNR INTO TDNAME.
    CALL FUNCTION 'READ_TEXT'
        EXPORTING
            ID = 'ZAT2'
            LANGUAGE = SY-LANGU
            NAME = TDNAME
            OBJECT = 'VBBP'
         IMPORTING
            HEADER = MYHEADER
         TABLES
            LINES  = LINES
    EXCEPTIONS
            ID = 1
            LANGUAGE = 2
            NAME = 3
            NOT FOUND = 4
            OBJECT= 5
            REFERENCE_CHECK = 6
            WRONG_ACCESS_TO_ARCHIVE = 7
            OTHERS = 8.
    IF SY-SUBRC = 0.
      LOOP AT LINES.
        MOVE LINES-TDLINE TO TEXT.
        ENDLOOP.
    ENDIF.

    Hi -
    Please check in debuging.
    check the value of TDNAME correctly populated with sales order no and sales order item.
    You can cross check with the table STXH with TDNAME and see if any entries is available for TDID 'ZAT2' as your case.
    Here are sample code.
    DATA :    lv_tdname TYPE tdobname,
                     lw_line TYPE tline,
                    li_line TYPE STANDARD TABLE OF tline.
    CLEAR : lv_tdname , li_line[],
    cocatenate w_vbak-vbeln w_vbap-posnr into lv_tdname.
    CALL FUNCTION 'READ_TEXT'
      EXPORTING
        id                      = 'ZAT2'
        language                = 'E'
        name                    = lv_tdname
        object                  = 'VBBP'
      TABLES
        lines                   = li_line
      EXCEPTIONS
        id                      = 1
        language                = 2
        name                    = 3
        not_found               = 4
        object                  = 5
        reference_check         = 6
        wrong_access_to_archive = 7
        OTHERS                  = 8.
    IF sy-subrc = 0.
      CLEAR lw_line.
      loop at li_line INTO lw_line .
    * Put your logic
      endloop.
    ENDIF.

  • How to put text line just for a moment ?

    Hi,
    Do you know how to put a text line  just  for one photo? I mean I have more photos  in one portfolio but i need the text line to be seen just for one photo for the others no.
    Thank you in advance.

    You can use composition for this , where you can insert text frame for that specific photo where you want to add some description and for rest dont use text frame.
    Thanks,
    Sanjit

  • Copy A/R Invoice to Credit Memo SBO 2007

    Hello All,
    I am currently facing an issue on SBO 2007.
    I have an A/R Invoice and I want to copy it into Credit Memo. I am able to use COPY TO on A/R invoice form. But I am not able to use COPY FROM on form Credit Memo... The invoice is not on the list of all the invoices for this customer to select.
    This issue happened only for this one invoice.
    Thank you in advance for your help.
    Regards
    Petr

    Hello,
    there is one credit memo already done for this invoice (about 1/3 of invoice) and for the rest is open balance in place. The invoice has status open.
    I do not know how was the first credit memo done (from form Invoice - copy to or from form Credit memo copy from - but still should not affect other credit memo and theit creation)
    Thank you in advance
    Regards
    Petr

  • How to create a subtotal or text line in a service sales order ?

    Hi ,
    is there a way to add text line in sales order for service ? when we switch from item sales order to service sales order , the "type" column disappear , and we can not create line other than service line . we use B12007A SP01 PL07
    i've not seen this limitation in the B1 help . is it a setup problem ? or is it impossible to add those lines to service sales order ?
    thanks for help
    regards

    Hi,
    This is not setup problem this is limitation you cannot add line as text or subtotal using type option in service order like item type order. If you want to add text for your service line you can do this through linewise  udf.
    Thanks
    Sachin

  • G/L Account Determination Document for SBO 2007

    I would like to find a document (word, excel or pdf) that explains the G/L Account Determination and its accounts. In which documents inside SBO are those account used? I see more accounts used in SBO 2007 and use trial and error to see these but preferred a document. I have seen the empowerment session about account determination but do not explain each of the accounts. Any help ?

    Sorry for attaching wrong thread .
    Please refer to the following information
    g/l Account Determination ---> purchase ---> Expense Account
    Define an expense account to be used as the default when a transaction of domestic purchasing is posted, for example, an A/P invoice. The system also selects this account as a default when you create new warehouses, item groups, and item master data records.
    The expense account is applicable only when you use non-inventory items.
    g/l Account Determination ---> purchase ---> Purchase Credit Account
    Define an expense account to be used as default when a credit transaction for purchasing is created, for example, an A/P credit memo.
    This account defaults for new warehouses, item groups and item master data records creation.
    The purchase credit account can be the same as the Expense Account, in case you do not wish to record credits to a separate account.
    Setup g/l Account Determination ---> inventory ---> Expense Clearing Account
    Define an offsetting G/L account to clear journal entries created by A/P invoices and goods receipt POs. This G/L account is used in journal entries when the Allocation account is also involved.
    Setup g/l Account Determination ---> inventory ---> Goods clearing Account
    When you close goods receipt POs or goods returns, this account is used as an offsetting account to the Allocation account. In this case, the system does not register an inventory transaction; however, it creates a journal entry involving this G/L account.
    Clearing account: An account to which postings are recorded temporarily because of a time gap between accounting transactions, organizational task distribution, or accounting transactions requiring clarifications.
    No matter what kinds of clearing accounts, they will be temparary accounts per se.
    Link for Archive Sessions:
    http://service.sap.com/~sapidb/011000358700000131752007E/ExpertSessions.htm
    And more information ,you can take a look at help file by hitting F1key
    Hope this helps.
    Bishal

  • PLD - SO needs to display Text line

    Dear All,
    Our customer's marking documents has text type lines. When I tried to print it on A/R invoice and A/R down payment invoice, it works good. When I tried to print it on Sales Order, text lines have always been printed first. Then items and subtotals. I use exactly the same way to print it.
    Field_1: Sys Var 157 (line type)
    Field_2: Field_1 == 'T'
    Field_3: Field_2 != 'T'
    Field_4: Sales Order - Rows.Text, link to Field_2
    Other item fields link to Field_3
    One more question for PLD is, I found in system PLD almost all the fields link to itself. It there any specfic reason we have to do that?
    Thanks a lot.
    Regards,
    Yuka

    Dear Yuka,
    You may check these threads first to see if there are any helps:
    Re: Row Type: "Text" >> in A/P invoice, not being displayed in PLD
    PO PLD Add line text....
    Line type text not printing
    Thanks,
    Gordon

  • My group box is causing problems when searching for a text line in a text file.

    I am developing a booking system, so for this I need to ensure that no two clients can book the same appointment slot. So, on testing my code which prevents double booking, the system doesn't seem to find the text line being searched for in the text file
    when it (purposefully) should.
    I have tried isolating the problem using breakpoints, and I've found that when the 'SearchLine' (referring to my code below) does not include the 'TimeComboBox.text' piece and instead this value is written into the code, the system is able to find the SearchLine
    without any problems. But, when assigning the group box's value to a variable and using this in the SearchLine instead, or without even using a loop and just doing a simple line by line search, the program can't find this line of text in the file.
    I'm lost for ideas. I have tried everything I can think of. Could anyone make any suggestions as for what is the problem with my group box? (I'll explain the code beneath it).
    'Setting the value of the SearchLine (which is a String)
    SearchLine = String.Concat(DateTimePicker1.Value.Date & " " & TimeComboBox.text)
    Dim FoundApp As Boolean
    Dim objReader As New System.IO.StreamReader(basicfilepath & "Text Files\Client Booked Appointment DatesTimes.txt")
    FoundApp = False
    'Reading the file's contents and checking for the SearchLine
    Do While (objReader.Peek() <> -1) or (FoundApp = True)
    If (TextLine = SearchLine) Then
    'Line contains SearchLine. Appointment already exists.
    FoundApp = True
    Else
    'Line doesn't contain SearchLine. Carry on searching.
    Msgbox("Line not found.")
    End if
    Loop
    Explanation
    When the line is searched for, the 'FoundApp' value must be set to 'True' when it is found. If it is not found, it remains false.
    To isolate the problem, I've displayed the SearchLine in a message box in the past to make sure that the correct line of text is being searched for.
    In basic terms, my program is searching for the exact line of text which exists in the text file, but for some reason it is not coming up as 'Found'. The error occurs when the group box's value is used. The text file which is being read is
    definitely correct. Please help, any suggestions would be appreciated.
    Thank you

    Hi
    It would appear that your snippet doesn't actually read the file at all.
    Here is my test which works fine.
    Option Strict On
    Option Infer Off
    Option Explicit On
    Public Class Form1
    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles Me.Load
    Dim SearchLine As String = "18:09:38 : XTaskSettings.Load PARAMS: begin"
    Dim FoundApp As Boolean = False
    Dim TextLine As String = Nothing
    Dim objReader As New IO.StreamReader(Application.StartupPath & "\Data\Report Q1.txt")
    FoundApp = False
    Do While (objReader.Peek() <> -1) Or (FoundApp = True)
    ' this was missing
    TextLine = objReader.ReadLine
    If (TextLine = SearchLine) Then
    'Line contains SearchLine. Appointment already exists.
    FoundApp = True
    MsgBox("Line found.")
    Else
    'Line doesn't contain SearchLine. Carry on searching.
    MsgBox("Line not found.")
    End If
    Loop
    End Sub
    End Class
    Regards Les, Livingston, Scotland

  • Dropping characters in text lines (FM8)

    I'm experiencing problems with dropped characters in text lines. Also, I've noticed the history doesn't seem to log all changes made to text lines. The problem can be duplicated as follows:
    1. Open a new portrait blank document and add an anchored frame. (recorded in history)
    2. Add a text line inside the anchored frame from the Tools Palette. In the text line, type "1234" (recorded in history).
    3. Save the file. (history cleared)
    4. Click the cursor after the "4" in the text line and hit a carriage return to create a new text line. (not recorded in history)
    5. In the new text line, type "1234567890"(not recorded in history)
    6. Save the file.
    7. Refresh the screen (cntl l) and the second text line now reads "12346890" (dropped the 5 and 7). Printing the file in steps 5 and 6 also show the 5 and 7 are missing.
    8. Add a new text line inside the anchored frame from the Tools Palette. In the text line, type "12345" (recorded in history).
    9. Save the file. (history cleared)
    10. Click the cursor after the "5" in the text line from step 8 and hit a carriage return to create a new text line. (not recorded in history)
    11. In the new text line, type "1234567890"(not recorded in history)
    12. Save the file.
    13. Refresh the screen and the second text line now reads "12345790" (dropped the 6 and 8).
    Has anyone else seen this problem (or can duplicate it)?
    Also, can someone explain why some of the steps above are not recorded in the history.
    FYI, while trying to find a repeatable sequence to demonstrate this problem, Frame crashed on me.
    I'm running a trial version of Frame 8, version 8.0p273, with XP Pro, on a fairly new Dell Optiplex 740.
    Thanks,
    Jeff Schweiner

    Hi Jeff,
    I have now tried what you're doing and get the same result!
    I have also added a text line with characters a to z. After saving ad doing a ctrl-l, the character after the last one, and the character second after that, in the previous line, was removed. (I first typed "abcd", saved, made a new line, typed "abcdefghi", saved, made ctrl-l, the characters "e" and "g" were removed).
    I have the same version of FrameMaker + SGML, but this is a licensed version, running on Win 2000.
    Regards
    Mikael Sten

  • Dynamic Text line spacing issue

    Hi, in my Flash movie (CS3) I want all text to be selectable.
    When I select 'static' and 'selectable', I have the following issues:
    - Some of the text does not fit into the available (scrolling required to see the end of text)
    - This is larger than when in Flash.
    When I use 'dynamic' text, I have the following issues:
    - The line spacing displays different in the exported swf than it does in Flash (line spacing is much greater in the swf)
    - I am a designer so the appearance / positioning of the text is crucial
    Is this common?
    Is there any way to make the text in Flash and swf appear consistent?
    Many thanks

    First of all, maybe you don't know it, but static text can't be made selectable even in theory. Therefore what you're seeing when you click "Selectable" option, is a dynamic text. As for line spacing, I don't see any difference between Flash CS4 and resulting SWF. The only strange thing I've found is the necessarity to enlarge the bounding rectangle when I change the text type from static to dynamic. Otherwise bottom line of text just disappears. It looks like a bug. Also I don't see "Autosize" option being working here in CS4. I doubleclick on bottom right corner of the text block, small square is transformed into a diamond, and bounding rect is "autosized" around the text block. But the bottom text line disappears just as I deselect the text object. All it looks some stange...

Maybe you are looking for

  • How to Export an Order Via XML

    How can we "Export an Order Via XML" using OOTB classes as mentioned in ATG Commerce Programming Guide?

  • 3450 printer offline, can't get it to print!

    I just hooked up a (new-- I know it's old, but I got it with my MacBook Pro 1.5 yr ago, and am only now using it) deskjet 3450 printer to my macbook pro (OSx 10.6), and I cannot get it to print. "Printer is offline" I don't necessarily want wireless,

  • Problem in Sales Order Credit Memo

    Hello All, The problem is related to item category ZTAN where we have changed the Completion Rule to B and in VTAF ( Bill to Order Copy Control) under Item details for Credit Memo Request for example from Domestic Invoice to Credit Memo we changed th

  • Use iBook in lid closed mode

    I was wondering if there is a free program that lets you modify the iBook to not sleep when the lid is closed down. I know there is risk of getting too hot, but I'm not gonna be doing major graphics stuff. Thanks.

  • WLC Upgrades to 7.5.102.0 from 7.4.100.0 Question

    We went through an upgrade from 7.4.100.0 for all of our WLC's this morning.  One of the interesting features, that we wanted to take advantage of, was the BYOD profiling that the release notes talk about.  I'm going through the controllers and see t