Problem in assigning characteristics values to characters against material
Hello Gurus,,
I am doing a wrapper RFC to populate characteristic values to characters and finally that needs to be visible in material classfication view.
The following is my code let me know if any thing needs to be corrected on this
*"*"Local Interface:
*" IMPORTING
*" VALUE(CLASSNUM) TYPE BAPI1003_KEY-CLASSNUM
*" VALUE(CLASSTYP) TYPE BAPI1003_KEY-CLASSTYPE
*" VALUE(MATNR) TYPE MATNR
*" TABLES
*" CHARVALUES STRUCTURE ZCLASSCHAR
*" RETURN STRUCTURE BAPIRET2
TYPES: BEGIN OF ty_classchar,
atnam TYPE atnam,
atfor TYPE atfor,
END OF ty_classchar.
DATA: t_classchar TYPE TABLE OF ty_classchar,
x_classchar TYPE ty_classchar,
v_matnr(50) TYPE c.
DATA: objectkeynew TYPE bapi1003_key-object,
objecttablenew TYPE bapi1003_key-objecttable,
classnumnew TYPE bapi1003_key-classnum,
classtypenew TYPE bapi1003_key-classtype,
status TYPE bapi1003_key-status,
standardclass TYPE bapi1003_key-stdclass,
changenumber TYPE bapi1003_key-changenumber,
keydate TYPE bapi1003_key-keydate,
no_default_values TYPE bapi1003_key-flag,
classif_status TYPE bapi1003_key-status.
DATA: allocvaluesnum TYPE TABLE OF bapi1003_alloc_values_num WITH HEADER LINE,
allocvalueschar TYPE TABLE OF bapi1003_alloc_values_char WITH HEADER LINE,
allocvaluescurr TYPE TABLE OF bapi1003_alloc_values_curr WITH HEADER LINE.
REFRESH: t_classchar,return.
IF charvalues IS NOT INITIAL.
SELECT atnam
atfor
FROM cabn
INTO TABLE t_classchar
FOR ALL ENTRIES
IN charvalues WHERE
atnam EQ charvalues-characteristic.
IF sy-subrc <> 0.
CLEAR return.
return-message = 'No values in CABN against provided input'.
APPEND return.
ENDIF.
ELSE.
CLEAR return.
return-message = 'No input is provided'.
APPEND return.
ENDIF.
REFRESH: allocvalueschar,allocvaluesnum.
LOOP AT charvalues.
CLEAR x_classchar.
READ TABLE t_classchar INTO x_classchar WITH KEY atnam = charvalues-characteristic.
CASE x_classchar-atfor.
WHEN 'NUM'.
CLEAR allocvaluesnum.
allocvaluesnum-charact = charvalues-characteristic.
allocvaluesnum-value_from = sy-datum.
APPEND allocvaluesnum.
WHEN 'CHAR'.
CLEAR allocvalueschar.
allocvalueschar-charact = charvalues-characteristic.
allocvalueschar-value_char = charvalues-description.
APPEND allocvalueschar.
ENDCASE.
ENDLOOP.
CLEAR: v_matnr.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = matnr
IMPORTING
output = v_matnr.
CALL FUNCTION 'BAPI_OBJCL_CREATE'
EXPORTING
objectkeynew = v_matnr
objecttablenew = 'MARA'
classnumnew = classnum
classtypenew = classtyp
STATUS = '1'
* STANDARDCLASS =
* CHANGENUMBER =
keydate = sy-datum
NO_DEFAULT_VALUES = ' '
IMPORTING
classif_status = classif_status
TABLES
allocvaluesnum = allocvaluesnum
allocvalueschar = allocvalueschar
* ALLOCVALUESCURR =
return = return
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
The output which i got has following error codes
I CL 732 Assignment does not exist or is not valid on
E CL 763 Object 00000000000000000000000000000000000000000000001631 does not exist
I CL 736 Assignment was not created
Please let me know what could be the error.
Regards
S.Janagar
Hi Mr.Sengathir Jeyamani,
Did u got the solution for this? Me also looking answer for your question. If u found, Pls let me know. Thanks.
-JANARAJA
Similar Messages
-
Problem in assigning Database Value to jTextfield (form doesn't show up)
Hi,
I'm trying to get an integer value from database, add 1 to it and assign it to a jTextfield in formInternalFrameOpened event, but this causes the form not to open.
If I remove just this thing the rest of the form works fine.
The open event has no problem it works fine, I have checked with jOptionDialog.
heres the code
private void formInternalFrameOpened(javax.swing.event.InternalFrameEvent evt) {
// Get last driver ID, add 1 to it and assign it to driver ID JTextField
Connection con = null;
try
MyDBConnection myDBConnection = new MyDBConnection();
myDBConnection.init();
con = myDBConnection.getMyConnection();
Statement pullStmt = con.createStatement();
ResultSet pullRs = pullStmt.executeQuery("SELECT key_driverId FROM drivers ORDER BY key_driverId DESC LIMIT 1");
pullRs.first();
driverId.setText(String.valueOf(pullRs.getInt("key_driverId")+1));
pullRs.close();
con.close();
catch(SQLException e){}
}Thanks, here it is.... Remember, I'm trying to insert a value from database into jTextfield in formInternalFrameOpened event.
* NewDriver.java
* Created on August 9, 2007, 9:14 AM
package LimoApp;
import java.sql.*;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import javax.swing.JOptionPane;
* @author NKA
public class NewDriver extends javax.swing.JInternalFrame {
/** Creates new form NewDriver */
public NewDriver() {
initComponents();
/** This method is called from within the constructor to
* initialize the form.
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
// <editor-fold defaultstate="collapsed" desc=" Generated Code ">
private void initComponents() {
jPanel1 = new javax.swing.JPanel();
driverId = new javax.swing.JTextField();
firstName = new javax.swing.JTextField();
jLabel1 = new javax.swing.JLabel();
jLabel2 = new javax.swing.JLabel();
jLabel3 = new javax.swing.JLabel();
jLabel4 = new javax.swing.JLabel();
lastName = new javax.swing.JTextField();
jLabel5 = new javax.swing.JLabel();
address = new javax.swing.JTextField();
jLabel6 = new javax.swing.JLabel();
city = new javax.swing.JTextField();
jLabel7 = new javax.swing.JLabel();
state = new javax.swing.JComboBox();
jLabel8 = new javax.swing.JLabel();
zipcode = new javax.swing.JTextField();
jLabel9 = new javax.swing.JLabel();
workPhone = new javax.swing.JTextField();
jLabel10 = new javax.swing.JLabel();
extention = new javax.swing.JTextField();
jLabel11 = new javax.swing.JLabel();
homePhone = new javax.swing.JTextField();
jLabel12 = new javax.swing.JLabel();
mobilePhone = new javax.swing.JTextField();
jLabel13 = new javax.swing.JLabel();
dispatchEmail = new javax.swing.JTextField();
personalEmail = new javax.swing.JTextField();
jPanel3 = new javax.swing.JPanel();
licenseNumber = new javax.swing.JTextField();
jLabel18 = new javax.swing.JLabel();
socialSecurityNumber = new javax.swing.JTextField();
jLabel19 = new javax.swing.JLabel();
dateOfBirth = new javax.swing.JTextField();
jLabel20 = new javax.swing.JLabel();
hireDate = new javax.swing.JTextField();
jLabel21 = new javax.swing.JLabel();
vehicleAssigned = new javax.swing.JComboBox();
jLabel22 = new javax.swing.JLabel();
jPanel4 = new javax.swing.JPanel();
payWaitingTime = new javax.swing.JCheckBox();
payExtraStops = new javax.swing.JCheckBox();
payEarlyLate = new javax.swing.JCheckBox();
payTolls = new javax.swing.JCheckBox();
payParking = new javax.swing.JCheckBox();
payGasSurcharge = new javax.swing.JCheckBox();
gratuity = new javax.swing.JTextField();
jLabel14 = new javax.swing.JLabel();
jLabel15 = new javax.swing.JLabel();
commission = new javax.swing.JTextField();
perHourRate = new javax.swing.JTextField();
perMileRate = new javax.swing.JTextField();
jLabel16 = new javax.swing.JLabel();
jLabel17 = new javax.swing.JLabel();
btNewDriverSave = new javax.swing.JButton();
setClosable(true);
setIconifiable(true);
setTitle("New Driver");
addInternalFrameListener(new javax.swing.event.InternalFrameListener() {
public void internalFrameActivated(javax.swing.event.InternalFrameEvent evt) {
public void internalFrameClosed(javax.swing.event.InternalFrameEvent evt) {
public void internalFrameClosing(javax.swing.event.InternalFrameEvent evt) {
public void internalFrameDeactivated(javax.swing.event.InternalFrameEvent evt) {
public void internalFrameDeiconified(javax.swing.event.InternalFrameEvent evt) {
public void internalFrameIconified(javax.swing.event.InternalFrameEvent evt) {
public void internalFrameOpened(javax.swing.event.InternalFrameEvent evt) {
formInternalFrameOpened(evt);
jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Driver", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11), new java.awt.Color(102, 0, 0)));
driverId.setEditable(false);
driverId.setHorizontalAlignment(javax.swing.JTextField.RIGHT);
firstName.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
firstNameFocusLost(evt);
jLabel1.setText("Dispatch Email");
jLabel2.setText("Personal Email");
jLabel3.setText("Driver ID");
jLabel4.setText("First Name");
lastName.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
lastNameFocusLost(evt);
jLabel5.setText("Last Name");
jLabel6.setText("Address");
jLabel7.setText("City");
state.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "AL", "VA" }));
jLabel8.setText("State");
zipcode.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
zipcodeFocusLost(evt);
jLabel9.setText("Zipcode");
workPhone.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
workPhoneFocusLost(evt);
jLabel10.setText("Work Phone");
extention.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
extentionFocusLost(evt);
jLabel11.setText("Extention");
homePhone.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
homePhoneFocusLost(evt);
jLabel12.setText("Home Phone");
mobilePhone.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
mobilePhoneFocusLost(evt);
jLabel13.setText("Cell");
dispatchEmail.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
dispatchEmailFocusLost(evt);
personalEmail.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
personalEmailFocusLost(evt);
javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
jPanel1.setLayout(jPanel1Layout);
jPanel1Layout.setHorizontalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGap(8, 8, 8)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addComponent(jLabel12)
.addComponent(jLabel10)
.addComponent(jLabel4)
.addComponent(jLabel3)
.addComponent(jLabel6)
.addComponent(jLabel7)))
.addComponent(jLabel1)
.addComponent(jLabel2))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(firstName, javax.swing.GroupLayout.PREFERRED_SIZE, 111, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jLabel5)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(lastName))
.addComponent(address)
.addComponent(dispatchEmail)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
.addComponent(workPhone, javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(city, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 112, Short.MAX_VALUE)
.addComponent(homePhone, javax.swing.GroupLayout.Alignment.LEADING))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(jLabel8)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGap(10, 10, 10)
.addComponent(jLabel11)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(extention, javax.swing.GroupLayout.PREFERRED_SIZE, 71, javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(state, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jLabel9)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(zipcode))))
.addGroup(jPanel1Layout.createSequentialGroup()
.addComponent(jLabel13)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(mobilePhone, javax.swing.GroupLayout.PREFERRED_SIZE, 111, javax.swing.GroupLayout.PREFERRED_SIZE))))
.addComponent(personalEmail)
.addComponent(driverId, javax.swing.GroupLayout.PREFERRED_SIZE, 63, javax.swing.GroupLayout.PREFERRED_SIZE))
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
jPanel1Layout.setVerticalGroup(
jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel1Layout.createSequentialGroup()
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel3)
.addComponent(driverId, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel4)
.addComponent(jLabel5)
.addComponent(lastName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(firstName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel6)
.addComponent(address, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel7)
.addComponent(city, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(state, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(jLabel8)
.addComponent(jLabel9)
.addComponent(zipcode, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(workPhone, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(jLabel10)
.addComponent(jLabel11)
.addComponent(extention, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel12)
.addComponent(jLabel13)
.addComponent(mobilePhone, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(homePhone, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel1)
.addComponent(dispatchEmail, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel2)
.addComponent(personalEmail, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
jPanel3.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Documents", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11), new java.awt.Color(102, 0, 0)));
licenseNumber.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
licenseNumberFocusLost(evt);
jLabel18.setText("License #");
socialSecurityNumber.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
socialSecurityNumberFocusLost(evt);
jLabel19.setText("Social Security #");
dateOfBirth.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
dateOfBirthFocusLost(evt);
jLabel20.setText("Date of Birth");
hireDate.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
hireDateFocusLost(evt);
jLabel21.setText("Hire Date");
vehicleAssigned.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
jLabel22.setText("Vehicle Assigned");
javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
jPanel3.setLayout(jPanel3Layout);
jPanel3Layout.setHorizontalGroup(
jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel3Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel3Layout.createSequentialGroup()
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addComponent(jLabel18)
.addComponent(jLabel19))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
.addComponent(socialSecurityNumber)
.addComponent(licenseNumber, javax.swing.GroupLayout.DEFAULT_SIZE, 104, Short.MAX_VALUE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 19, Short.MAX_VALUE)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addComponent(jLabel20)
.addComponent(jLabel21))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
.addComponent(hireDate)
.addComponent(dateOfBirth, javax.swing.GroupLayout.PREFERRED_SIZE, 77, javax.swing.GroupLayout.PREFERRED_SIZE)))
.addGroup(jPanel3Layout.createSequentialGroup()
.addComponent(jLabel22)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(vehicleAssigned, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
.addContainerGap())
jPanel3Layout.setVerticalGroup(
jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel3Layout.createSequentialGroup()
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel3Layout.createSequentialGroup()
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel18)
.addComponent(licenseNumber, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel19)
.addComponent(socialSecurityNumber, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
.addGroup(jPanel3Layout.createSequentialGroup()
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel20)
.addComponent(dateOfBirth, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(hireDate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(jLabel21))))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 9, Short.MAX_VALUE)
.addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(vehicleAssigned, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
.addComponent(jLabel22))
.addContainerGap())
jPanel4.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Payroll Stettings", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11), new java.awt.Color(102, 0, 0)));
payWaitingTime.setText("Pay Waiting Time");
payWaitingTime.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
payWaitingTime.setMargin(new java.awt.Insets(0, 0, 0, 0));
payExtraStops.setText("Pay Extra Stops");
payExtraStops.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
payExtraStops.setMargin(new java.awt.Insets(0, 0, 0, 0));
payEarlyLate.setText("Pay Early / Late");
payEarlyLate.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
payEarlyLate.setMargin(new java.awt.Insets(0, 0, 0, 0));
payTolls.setText("Pay Tolls");
payTolls.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
payTolls.setMargin(new java.awt.Insets(0, 0, 0, 0));
payParking.setText("Pay Parking");
payParking.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
payParking.setMargin(new java.awt.Insets(0, 0, 0, 0));
payGasSurcharge.setText("Pay Gas Surcharge");
payGasSurcharge.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
payGasSurcharge.setMargin(new java.awt.Insets(0, 0, 0, 0));
gratuity.setHorizontalAlignment(javax.swing.JTextField.RIGHT);
gratuity.setText("0");
gratuity.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
gratuityFocusLost(evt);
jLabel14.setText("Gratuity %");
jLabel15.setText("Commission %");
commission.setHorizontalAlignment(javax.swing.JTextField.RIGHT);
commission.setText("0");
commission.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
commissionFocusLost(evt);
perHourRate.setHorizontalAlignment(javax.swing.JTextField.RIGHT);
perHourRate.setText("0");
perHourRate.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
perHourRateFocusLost(evt);
perMileRate.setHorizontalAlignment(javax.swing.JTextField.RIGHT);
perMileRate.setText("0");
perMileRate.addFocusListener(new java.awt.event.FocusAdapter() {
public void focusLost(java.awt.event.FocusEvent evt) {
perMileRateFocusLost(evt);
jLabel16.setText("Per Mile Rate");
jLabel17.setText("Per Hour Rate");
javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);
jPanel4.setLayout(jPanel4Layout);
jPanel4Layout.setHorizontalGroup(
jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel4Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel4Layout.createSequentialGroup()
.addGap(16, 16, 16)
.addComponent(jLabel14)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(gratuity, javax.swing.GroupLayout.PREFERRED_SIZE, 52, javax.swing.GroupLayout.PREFERRED_SIZE)
.addGap(9, 9, 9)
.addComponent(jLabel16)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(perMileRate, javax.swing.GroupLayout.PREFERRED_SIZE, 51, javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(jPanel4Layout.createSequentialGroup()
.addComponent(jLabel15)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(commission, 0, 0, Short.MAX_VALUE)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(jLabel17)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(perHourRate, 0, 0, Short.MAX_VALUE))
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel4Layout.createSequentialGroup()
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(payWaitingTime)
.addComponent(payEarlyLate)
.addComponent(payExtraStops))
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 45, Short.MAX_VALUE)
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
.addGroup(jPanel4Layout.createSequentialGroup()
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(payParking)
.addComponent(payTolls))
.addGap(36, 36, 36))
.addComponent(payGasSurcharge))))
.addContainerGap())
jPanel4Layout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] {commission, gratuity, perHourRate, perMileRate});
jPanel4Layout.setVerticalGroup(
jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel4Layout.createSequentialGroup()
.addContainerGap()
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel14)
.addComponent(gratuity, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel16)
.addComponent(perMileRate, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
.addGap(14, 14, 14)
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
.addComponent(jLabel15)
.addComponent(commission, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
.addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
-
Problem in assigning variables value.. FORM bdc_field
Though the value is there in y_lv_fval it is not assigned to WA field y_li_bdcdata-fval.
FORM bdc_field USING y_lv_fnam y_lv_fval.
CLEAR y_li_bdcdata.
y_li_bdcdata-fnam = y_lv_fnam.
y_li_bdcdata-fval = y_lv_fval. "KBETR field length..larger than y_li_bdcdata-fval
APPEND y_li_bdcdata.
ENDFORM. "BDC_FIELDok
-
Assigning a value to an array cell populated [BULK]
Hi all,
I've got a problem in assigning a value to an array populated with BULK COLLECT INTO .
I can reproduce the problem with this
CREATE TABLE TEST_TABLE (
value1 NUMBER,
value2 NUMBER
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);
INSERT INTO test_table VALUES(1,1);And this is the PL/SQL anonymous block that gives me problems:
DECLARE
SUBTYPE t_rec IS TEST_TABLE%ROWTYPE;
TYPE records_table IS TABLE OF t_rec;
elist RECORDS_TABLE;
CURSOR table_cursor IS SELECT * FROM TEST_TABLE WHERE rownum <= 20;
BEGIN
OPEN table_cursor;
FETCH table_cursor BULK COLLECT INTO elist;
FOR j IN 1..elist.COUNT
LOOP
elist(j)(1) := elist(j)(1) +1;
END LOOP;
CLOSE table_cursor;
END; The error is
ORA-06550: line 13, column 7:
PLS-00308: this construct is not allowed as the origin of an assignment
ORA-06550: line 13, column 7:
PL/SQL: Statement ignored
06550. 00000 - "line %s, column %s:\n%s"
*Cause: Usually a PL/SQL compilation error.
*Action:So it doesn't compile because of this line of code:
elist(j)(1) := elist(j)(1) +1;
Why doesn't it work?
If I try to do this, works perfectly:
DECLARE
TYPE v_num_table
IS
TABLE OF NUMBER;
TYPE v_2_num_table
IS
TABLE OF v_num_table;
v_nums V_2_NUM_TABLE := V_2_NUM_TABLE();
BEGIN
v_nums.EXTEND;
v_nums(1) := v_num_table();
v_nums(1).EXTEND;
v_nums(1)(1) := 1;
v_nums(1)(1) := v_nums(1)(1) +1;
dbms_output.put_line(v_nums(1)(1) );
END;Edited by: user10396517 on 2-mar-2012 2.35Variable "elist" is a collection of record, so you access an individual field of a given collection element by specifying the field name, not its position :
DECLARE
SUBTYPE t_rec IS TEST_TABLE%ROWTYPE;
TYPE records_table IS TABLE OF t_rec;
elist RECORDS_TABLE;
CURSOR table_cursor IS SELECT * FROM TEST_TABLE WHERE rownum <= 20;
BEGIN
OPEN table_cursor;
FETCH table_cursor BULK COLLECT INTO elist;
FOR j IN 1..elist.COUNT
LOOP
elist(j).value1 := elist(j).value1 + 1;
END LOOP;
CLOSE table_cursor;
END;Your second example is different as you're dealing with a collection of collections. -
Problem in assigning date valje to field
Hi,
I have a problem in assignning date value to field.
i am retriving date from a table and assigning it to a field which is date type in the form.. but it is not reflecting..
Error: form Bad Value..
how to assign the date values in the form..
MahiHi mahendra,
I think the Bad Value Error Occurs only if the databound datasource in the form must have different data type...
oForm.DataSources.UserDataSources.Add("eDate", SAPbouiCOM.BoDataType.dt_DATE, 10);
SAPbouiCOM.EditText oEdit;
oEdit = oForm.Items.Item("1").Specific;
oEdit.DataBind.SetBound(true, "", eDate);
with Regards,
MadhuSudhana Rao.G -
Characteristics value assignments screen- the results button is not visible
Dear Gurus,
In variant configuration, while i am assignning characteristics values in the characteristics value assignments
screen, the results button is not visible. Even when I try to go to the results option from the Menu (GOTO > Results),
it is disabled.
Can any one tell me why is it so ?
RegardsHi
I have checked my config profile. it looks ok to me.
Can u suggest anything in particular that I need to check.
Rgds
Vishal Saha -
BDC/BAPI Assign characteristics to material using CL24n
Hi Gurus
My requirement is :
We have already assigned characteristics to the material class, Now we need to assign characteristics values to materials.
Assign characteristics to material using cl24n(Class name & Classtype) > only new assignments > material.
What should I go for ? BDC or BAPI.
Please suggest me how to proceed with BAPI as I personally feel BAPI is better than BDC.
Thanks in Advance
DineshBAPI/BDC for assigning characteristic to material
-
How check characteristics values in material user exit
Hi Forum,
we want to check characteristics values if a new material is created. All the other check we do we use the User exit EXIT_SAPLMGMU_001 (abap ZXMG0U02). But it is not possible to check the values a user entered here. Do somebody of you have an idea?
Regards
Bertholdtry to use:
BADI_MATERIAL_REF Addition of customer-defined default data for material
BADI_MATERIAL_CHECK Enhanced checks for material master table
WSTRN_STYLE BAdI to get the text for a char. value defined in check
BADI_MM_MATNR
pls. reward points if helpful
regards
Roberto -
Facing problem of Assigned Value in CJ33
Hi All,
I am facinfg a problem with Assigned value shown in CJ33 T code. My Sceneraio is like this.....
1. I have activated availiblity controll on Released Budget.
2. I have maintained tolerence limit only for PR and PO.
Now My problem is that I budgeted one of my WBS as INR2000, Same amount is released also. I created a PR for INR500. The same PR is converted to a Purchase order of INR500.
Now in CJ33 T code my assigned value is comming as INR1000. Which is not correct for me because i have only used INR500 for my INR2000 budget and i want to use my Remaining INR1500 budget for another PR, But system is giving me Budget excedded error.
Please advise. It would be a great help of all of you.
Regards
RahulHi Rahul,
Refer this thread,
Assigned Values For Project
I had a strong feelilng that you were using ECC 5.0. I had come across the same issue. Just refer the note and try to apply the notes mentioned there. I am not sure which one i had applied but you can try out with the note number that Muraleedharan has mentiond in the thread. It should work.
Kindly revert.
Best Regards,
Gokul -
Problem in assigning value to an array element
hi all
in the following prog i am not able to assign the value to the array element
i am not getting why it is giving me error
//my program is as follows
public class ArrayTest
static int [] intArray = new int[5];
static int [] intArray1 = new int[1];
intArray1[0] = 5; // this line gives error
static char [] charArray = new char[5];
public static void main(String args[])
System.out.println(charArray);
intArray1 = intArray;
}thanx in advance as usualThe problem is that you try to execute code outside a method. This can be only done in form of a variable declaration or as a static initilization block which will be executed once when the class is loaded:public class ArrayTest
static int [] intArray = new int[5];
static int [] intArray1 = new int[1];
static char [] charArray = new char[5];
static {
intArray[0] = 5;
public static void main(String args[])
System.out.println(charArray);
intArray1 = intArray;
} -
Assigning of characteristics value for a batch
Hi All,
Please help regarding the assigning of characteristics value for a batch in transaction code MSC2N or MSC2 in the classification tab.
If Function modules or BAPI is available pls advise the inputs to be provided for the function modules.
Here is one function module which i searched, but if i run this function module, i am not able to commit my characteristics value.
The function module is CIF_BATCHCHAR_MAP.
For the above function module the inputs which i have given are...
Material number
Batch
Plant
Class type
Class Number
Characteristics name
Characteristics value
Expecting your earliest reply.
Thanks,
G.C.Arravind Kumar VikramTry the code below
*.1 create key
it_objects-key_field = 'MATNR'.
it_objects-value_int = matnr.
APPEND it_objects.
it_objects-key_field = 'CHARG'.
it_objects-value_int = charge.
APPEND it_objects.
CLEAR l_objectkey.
CALL FUNCTION 'BAPI_OBJCL_CONCATENATEKEY'
EXPORTING
objecttable = 'MCH1'
IMPORTING
objectkey_conc = l_objectkey
TABLES
objectkeytable = it_objects
return = it_return2.
2 fill it_num it_char it_curr with values
3 change characteristics
CALL FUNCTION 'BAPI_OBJCL_CHANGE'
EXPORTING
objectkey = l_objectkey
objecttable = 'MCH1'
classnum = it_class-classnum
classtype = '023'
TABLES
allocvaluesnumnew = it_num
allocvaluescharnew = it_char
allocvaluescurrnew = it_curr
return = it_return. -
Enable/Disable Characteristics value assignment during Configuration in SD
Hi,
I have a sales order which has to be configured using Variant Configuration.
During the configuration process, I want to restrict the value assignment by classes. Meaning I have 2 classes - one for GRP1 and another for GRP2.
During creation of sales order, I give the sales ppl authorization to class for GRP1, which allows them to do characteristics value assignment for all the characteristics in the class called GRP1. The other users are not allowed to change any values assigned in GRP1 but they can view the info in GRP1, these users can only configure whatever characteristics in GRP2.
I tried using authorization object C_TCLS_MNT.
Mentioned in the SU21,
C_TCLS_MNT Authorization for Characteristics of Org. Area object can be used.
Actvt : 23 Maintenance of characteristics for org. area allowed , any other value Display area only characteristics for org.
However, I am unable to assign any other value other than 23. It mentioned that any other value is Display but I am unable to assign the other value.
It seems to be that C_TCLS_MNT is not working. Even when I do not assign C_TCLS_MNT (disable it) but using C_TCLS_BER (with org area), it allows user to do everything (display and change).
Pls help.
Thanks.
Cheers,
Sue> I tried using authorization object C_TCLS_MNT.
> Mentioned in the SU21,
> C_TCLS_MNT Authorization for Characteristics of Org. Area object can be used.
> Actvt : 23 Maintenance of characteristics for org. area allowed , any other value Display area only characteristics for org.
>
> However, I am unable to assign any other value other than 23. It mentioned that any other value is Display but I am unable to assign the other value.
Please assign the value as ' ' (Single space included within single quote) to use "Any other value" option.
The other Objects can be used here are:
C_CLMM CLAS Mass Processing of Classifications
C_TCLA_BKA CLAS Authorization for Class Types
C_TCLS_BER CLAS Authorization for Org. Areas in Classification System
C_TCLS_MNT CLAS Authorization for Characteristics of Org. Area
Please check how many of these are present for the TCode you are using in TCode SU24 as Check/Maintain (or Check Indicator = Check & Proposal = Yes : If you are in ECC).
The activity 23 means "maintain"
Regards,
Dipanjan -
FM to check Characteristics values assignment
Hi , Experts:
Can tell me which FM should I use to check if a Characteristics value has been assigned to a material?
Thanks for your help
SanweiI believe that there is no such FM. You need to build a range for your constant values and then compare your select option with the range build for constants.
Eg.
select-options: s_werks for t001w-werks.
ranges r_werks for t001-werks.
r_werks-sign = 'I'.
r_werks-option = 'EQ'.
r_werks-low = '2101'. "Pass the constant value.
append r_werks. "Range built for one entry 2101. Similarly append further constant values.
*Check if select option contains any of the constant values.
if s_werks in r_werks.
* Select-options contains value as defined in range
else.
* No matching value found.
endif. -
Problem with Assigning more than one value to GROUP dynamically
Hi,
I have a problem with assigning more than one value to GROUP varible dynamically.
I am able to assign only one value dynamically through Initialization block
I have even tried with the ROW-WISE initialization blocks..
using this query..
SELECT 'GROUP', G.GROUP_NAME
FROM GROUP_MAP G
WHERE G.USER_NAME = ':USER'
if GROUP_1, GROUP_2 are two groups to be associated,
through this, i'm getting " GROUP_1;GROUP_2 " into GROUP variable ( seen from Narative view )
And the properties and securities of this Groups are not inherited.
Please let me know if there is any other way to Populate the GROUP variable dynamically with more than one value.
Thank you.,Hi,
i finally got in this way..
i had created a function which takes USER_NAME as input and returns a string that contains the GROUP names with semicolon delimeted..
Though it is same as that of ROW-WISE initialization,
the properties of those groups are also being inherited..
Now, i can assign more than one groups and its properties to a user dynamically. -
Human task jsp customization assign calculated value problem...
We customize human task jsp and add some field.
We want assign a calculation result to a task variable...
autogenerated HTML inbup box name is slns0_cl_task_sl_ns0_cl_payload_sl_ns1_cl_bim_Myprocessname_myparametername..
is it possible to assign a value using this name ? is it correct way?
is there any other way yo do it..
Thanks...Thansk..
I tried to use javascript. but I need ro add a combobox to the payload body jsp page.
Because buid-in Oracle SOA procedures try to forward all parameters "object doesn't support this property error occurs..."
So question is ...
How can I add a combobox on payload body jsp pages ?
Thaks..
Maybe you are looking for
-
HiI need help connecting the MacBook pro to the HDTV. I have the attachment and have it connected but I want to play videos or video from the Internet and all I can see is the background screen of the Mac. Hope the solution is simple :)
-
Call .xhtml file from javascript function
Hi, Is there a way to call .xhtml page from javascript function???
-
Yet another "unable to find root device" problem (pacman issue) SOLVED
During this night I've been trying to solve a problem that let me without access to my ArchLinux partition. Booting the kernel. :: Starting udevd... done. :: Running Hook [udev] :: Triggering uevents...done. Waiting 10 seconds for device /dev/by-uuid
-
What's with the new lightning cords??
I've only had my iPhone for a year and I have already gone through 7 chargers. I know many other people that have had the same problem.. I'm so tired of buying new chargers that continue to fail me.
-
I want to use a form from a table because it will create all my ddl. However the table I want to use I have to get the description from other tables using a foreign key. Can this be done. Currently I am trying to do this with a report but I have to m