on 01-26-2004 2:41 PM
I cannot create user defined table using UserTablesMD object. The error message is : "The table name should consist of 3 alphanumeric characters [OUTB]". I have tried to use various table names like "XYZ" , "XY" , "@XYZ" , "@XY" but I still get this message. Is it a bug or I don't know about something ?
I got the same message when I tried to use my prefix:
PRE_XYZ
I solved it removing the underscore:
PREXYZ
it looks to me it is a bug.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Collagues
I will refer in my answer to both available versions:
In version 6.2:
Table name is limited to 3 characters the following code should work for you:
Dim RetVal As Long
Dim ErrCode As Long
Dim ErrMsg As String
Dim UTMD As SAPbobsCOM.UserTablesMD
Set UTMD = vCmp.GetBusinessObject(oUserTables)
UTMD.TableName = "ABC"
UTMD.TableDescription = "ABC Table"
RetVal = UTMD.Add
If RetVal <> 0 Then
vCmp.GetLastError ErrCode, ErrMsg
MsgBox "Failed to add UserTable " & ErrCode & " " & ErrMsg
End If
In version 6.5:
We did have a bug that blocked adding table name with "_" (which made it impossible to use the prefix). This bug was fixed in patch 3. (You can take the uprader from the market place - any higher patch has the fix as well)
Best Regards
Miki
I've got it !!! (GetByKey method destroys UTMD.TableName)
Try this:
Dim RetVal As Long
Dim ErrCode As Long
Dim ErrMsg As String
Dim UTMD As SAPbobsCOM.UserTablesMD
Set UTMD = vCmp.GetBusinessObject(oUserTables)
UTMD.TableName = "ABC"
If UTMD.GetByKey(UTMD.TableName) = False Then
UTMD.TableDescription = "ABC Table"
RetVal = UTMD.Add
If RetVal <> 0 Then
vCmp.GetLastError ErrCode, ErrMsg
MsgBox "Failed to add UserTable " & ErrCode & " " & ErrMsg
End If
Ebd If
Thanks, greetings from Poland,
Jarek
User | Count |
---|---|
103 | |
12 | |
11 | |
6 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.