How to avoid invalid data entering in LOV through code
hi
1)i have developed lov in table region, but user easily can enter invalid data and saved into the database tables.
2)i created one formvalue and mapping into that return item , still its not working in table region LOV.
3)how to avoid invalid data entering in LOV through code. i have tried this below code in EOimpl set value method. but some how its not wokring.
if (value!=null)
throw new OAAttrValException(OAAttrValException.TYP_ENTITY_OBJECT,
getEntityDef().getFullName(),
getPrimaryKey(),
"ProcurementCategory",
getProcurementCategory(),
"FND",
"FND_LOV_SELECT_VALUE");
Thanks.
krish.
Thanks reetesh and gourav for your help.
i followed below mapping details
LOV Item Properties
ID -PurcCommodity
ViewInstance -VendorVO1
ViewObject -PurcCommodity
map1 properties
LOV Region Item - segment1
Return Item -PurcCommodity
CriteriaItem -PurcCommodity
Usefor Validation -Default
map2 properties
LOV Region Item - segment1
Return Item -validation(formvalue)
CriteriaItem -
Usefor Validation -yes
form value properties
ID -validation
ViewInstance -VendorVO1
ViewObject -PurcCommodity
Gourav- i double checked multiple rows it is not working, some times it is not working for single row too.
Thanks
krish.
Similar Messages
-
How to capture the data entered in a textfield in a JTable
How to capture the data entered in a textfield present in a cell of a textfield or how to add listener to this textfield
A sample of my code is:
model = new GridDisplayTableModel(gridDisp,columnName,getRows(),getCols());
final ComboRenderer cRenderer = new ComboRenderer();
final TextFieldRenderer tRenderer = new TextFieldRenderer();
combo.addItem("one");
combo.addItem("two");
combo.addItem("three");
final JTextField textfield = new JTextField();
final DefaultCellEditor cmbEditor = new DefaultCellEditor(combo);
// final JEnterDataCellEditor textEditor = new JEnterDataCellEditor(12);
final DefaultCellEditor textEditor = new DefaultCellEditor(textfield);
rm = new RowEditorModel();
table = new JTable(model){
public TableCellRenderer getCellRenderer(int row, int column) {
int posx = 0;
int posy = 0;
TableCellRenderer renderer = null;
for(int l=0;l<getDataVec().size();l++)
beanObj =(Helperbean)dataVec.elementAt(l);
posx = beanObj.getPosx();
posy = beanObj.getPosy();
if(row==posx && column==posy)
if(beanObj.getModeofDisplay() != null && beanObj.getModeofDisplay().equalsIgnoreCase("textfield"))
rm.addEditorForRow(row,textEditor);
renderer = tRenderer;
else if(beanObj.getModeofDisplay() != null && beanObj.getModeofDisplay().equalsIgnoreCase("combo"))
rm.addEditorForRow(row,cmbEditor);
renderer = cRenderer;
break;
renderer = super.getCellRenderer(row, column);
// System.out.println("getEditor"+rm.getEditor(1));
return renderer;
public TableCellEditor getCellEditor(int row, int col) {
int posx = 0;
int posy = 0;
TableCellEditor tmpEditor = null;
for(int l=0;l<getDataVec().size();l++)
beanObj =(Helperbean)dataVec.elementAt(l);
posx = beanObj.getPosx();
posy = beanObj.getPosy();
if(row==posx && col==posy)
if(beanObj.getModeofDisplay() != null && beanObj.getModeofDisplay().equalsIgnoreCase("textfield"))
System.out.println("celleditorval "+textEditor.getCellEditorValue());
tmpEditor = textEditor;
else if(beanObj.getModeofDisplay() != null && beanObj.getModeofDisplay().equalsIgnoreCase("combo"))
tmpEditor = cmbEditor;
break;
tmpEditor = super.getCellEditor(row, col);
return tmpEditor;
public boolean isCellEditable(int row,int col){
boolean isEditable = false;
int posx = 0;
int posy = 0;
for(int l=0;l<getDataVec().size();l++)
beanObj =(Helperbean)dataVec.elementAt(l);
posx = beanObj.getPosx();
posy = beanObj.getPosy();
if(row==posx && col==posy)
if(beanObj.getModeofDisplay() != null )
isEditable = true;
else
isEditable = false;
break;
isEditable = false;
return isEditable;
public void changeSelection(final int row, final int column, boolean toggle, boolean extend) {
super.changeSelection(row, column, toggle, extend);
//my attempt to avoid editCellAt from being called twice in a row
if (getModel().isCellEditable(row, column) && !(isEditing() && getEditingRow() == row && getEditingColumn() == column))
if (editCellAt(row, column)) {
getEditorComponent().requestFocus();
// Select the text when the cell starts editing
public boolean editCellAt(int row, int column) {
boolean result = super.editCellAt(row, column);
final Component editor = getEditorComponent();
if (editor != null && editor instanceof JTextField) {
SwingUtilities.invokeLater(new Runnable() {
public void run() {
((JTextField)editor).selectAll();
return result;
public boolean hasFocus()
Component editorComponent = getEditorComponent();
// Try to install the editor
int anchorRow = getSelectionModel().getAnchorSelectionIndex();
int anchorColumn = getColumnModel().getSelectionModel().
getAnchorSelectionIndex();
if (anchorRow != -1 && anchorColumn != -1 && !isEditing())
if ((this.getSelectedRow() == anchorRow) && (this.getSelectedColumn() == anchorColumn))
if (!editCellAt(anchorRow, anchorColumn)) {}
return super.hasFocus();
public void valueChanged(ListSelectionEvent e)
super.valueChanged(e);
if ((this.getSelectedRow() == 2) && (this.getSelectedColumn() == 3))
DefaultFocusManager focusManager = new DefaultFocusManager();
focusManager.focusNextComponent(this);
model.fireTableStructureChanged();
-
How to avoid clear data in the block in a form
Hi All
I am using Oracle form 10g and db 10g.
My form i have a list item in my main canvas. It has a value of (EXPENSE,AMOUNT,SUPPLIER,ACCOUNT).
The user used to select the list item one by one and used to enter values in the each canvas assigned to the Item(expense,amount,supplier,account) and go for a save.
For instance when the user enter the value in expense ,amount and supplier and again back when the user navigate back to amount the entered value get cleared.
how to avoid the data get cleared.
Thanks & regards
Srikkanthyou can use EXECUTE_QUERY built-in to populate the data when that canvas or block instance. If it need at block level write this at When New Block Instance. if it a tab page then you can write when tab page change. If need where condition, add block level where condition.
-
Unable to email a document. Keep getting error message: Invalid Date Enter 2-digit month
Does not happen with all forms which emante from same USG webpage
Any adivice?If i am using 11G andrtp is 11g but on rtp side if they configure SSL, is it mandatory to do it from our side also?No it not mandatory to enable SSL at your end however you have to configure identity and trsut at your end.
Any update on my regular question(The main forum question)?You mentioned that you are posting message from 10g to 11g and as per log you are sending it to URL - https://dev-nog.server:443/b2b/transportServlet
So few things which I see as a problem are-
1. You should use URL https://hostname:soa_server_ssl_port/b2b/httpReceiver instead of https://dev-nog.server:443/b2b/transportServlet
2. SOA server SSL port should be enabled (SSL should be enabled on SOA server)
3. You should configure wallet at 10g side to contain trust cert of 11g server
Regards,
Anuj -
How to keep the data entered on a page apex
how to keep the data entered on a page apex
so, I've got a registration page then wish go to another page P2 and I return to this P1 without losing dataHi,
As long as the registration page is within the same session, the values will remain in the session until they are specifically cleared out. This can be done by a process on a page - so check if you have a "reset page" process on P1 and, if you do, delete it. This can also be done on a branch - so check the branch that takes you to P2 and see if there is anything entered in the Clear Cache setting and, if it shows *1*, remove that. There are other ways as well, but these are most typical.
Andy -
How to avoid duplicate data while inserting from sample.dat file to table
Hi Guys,
We have issue with duplicate data in flat file while loading data from sample.dat file to table. How to avoid duplicate data in control file.
Can any one help me on this.
Thanks in advance!
Regards,
LKRNo, a control file will not remove duplicate data.
You would be better to use an external table and then remove duplicate data using SQL as you query the data to insert it to your destination table. -
How many times can you enter the wrong pin code on an iphone before it resets?
How many times can you enter the wrong pin code on an iphone before it resets itself?
Hey Robin.T,
Thanks for the question. The following article provides the answer to your question:
iOS: Forgotten passcode or device disabled after entering wrong passcode
http://support.apple.com/kb/HT1212
If you enter the wrong passcode six or more times, you'll see a message that says one of the following:
iPhone is disabled
iPad is disabled
iPod touch is disabled
You can also set your passcode lock to wipe the device after 10 unsuccessful attempts (Settings > General > Passcode Lock > Erase Data)
Thanks,
Matt M. -
How to avoid duplicates values from alvgird see below code
how to avoid duplicates values from alvgird see below code
in below query docno no is repeated again and again
how i can avoid duplication in this query.
select * into corresponding fields of table itab
from J_1IEXCHDR
inner join J_1IEXCDTL
on J_1IEXCDTLlifnr = J_1IEXCHDRlifnr
where J_1IEXCHDr~status = 'P'.Hi Laxman,
after that select statement
select * into corresponding fields of table itab
from J_1IEXCHDR
inner join J_1IEXCDTL
on J_1IEXCDTLlifnr = J_1IEXCHDRlifnr
where J_1IEXCHDr~status = 'P'.
<b>if sy-subrc = 0.
delete adjucent duplicates from itab comparing <field name of itab internal table>
endif.</b>
this will delete your duplicate entries.once you done with this call the alv FM.
<b> call function 'REUSE_ALV_GRID_DISPLAY'</b>
exporting
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER = ' '
I_BUFFER_ACTIVE = ' '
i_callback_program = v_repid
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = 'IT_USER_COMMAND'
I_CALLBACK_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_END_OF_LIST = ' '
I_STRUCTURE_NAME =
I_BACKGROUND_ID = ' '
i_grid_title = 'Purchase Order Details'
I_GRID_SETTINGS = I_GRID_SETTINGS
is_layout = wa_layout
it_fieldcat = it_fieldcat
IT_EXCLUDING = IT_EXCLUDING
IT_SPECIAL_GROUPS = IT_SPECIAL_GROUPS
it_sort = it_sort
IT_FILTER = IT_FILTER
IS_SEL_HIDE = IS_SEL_HIDE
I_DEFAULT = 'X'
I_SAVE = ' '
IS_VARIANT = IS_VARIANT
it_events = it_event
IT_EVENT_EXIT = IT_EVENT_EXIT
IS_PRINT = IS_PRINT
IS_REPREP_ID = IS_REPREP_ID
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
I_HTML_HEIGHT_TOP = 0
I_HTML_HEIGHT_END = 0
IT_ALV_GRAPHICS = IT_ALV_GRAPHICS
IT_HYPERLINK = IT_HYPERLINK
IT_ADD_FIELDCAT = IT_ADD_FIELDCAT
IT_EXCEPT_QINFO = IT_EXCEPT_QINFO
IR_SALV_FULLSCREEN_ADAPTER = IR_SALV_FULLSCREEN_ADAPTER
IMPORTING
E_EXIT_CAUSED_BY_CALLER = E_EXIT_CAUSED_BY_CALLER
ES_EXIT_CAUSED_BY_USER = ES_EXIT_CAUSED_BY_USER
tables
<b> t_outtab = ITAB</b>
exceptions
program_error = 1
others = 2
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif.
Thanks
Vikranth Khimavath -
How to store Invalid Dates in SQL Server 2008
Hi,
I have SQL Server 2008 and My table has start_Date and end_date column which is DATETIME datatype.
Somehow my table is having invalid dates which is lesser than 1753-01-01 00:00:00.0 range.
I want to know how this date get inserted in the SQL Server.
Thanks,
MuthuprabhuCan you post the DDL for that table together with a SELECT query and results demonstrating invalid data?
DECLARE @dt DATETIME = '1753-01-01 00:00:00.0';
-- Command(s) completed successfully.
DECLARE @dt DATETIME = '1752-01-01 00:00:00.0';
Msg 242, Level 16, State 3, Line 4
The conversion of a varchar data type to a datetime data type resulted in an out-of-range value.
Datetime conversion:
http://www.sqlusa.com/bestpractices/datetimeconversion/
Kalman Toth Database & OLAP Architect
SQL Server 2014 Database Design
New Book / Kindle: Beginner Database Design & SQL Programming Using Microsoft SQL Server 2014 -
Parameter Validation for invalid date entered
I enter an invalid date like 99/08/2014 as one of the parameters for my report and get the following error.
The value provided for the report parameter 'P1' is not valid for its type. (rsReportParameterTypeMismatch)
To the report user audience, this message is not meaningful and it happened before the report is even executed .
Is there any way to override this and put a more meaningful error in ?Hello,
According to your description, you want to custom the error message when the input date value is invalid. In Reporting Services, it doesn’t provide any interference for us to modify the system error message (the text in grey color). That means we can’t modify
the system message when error occurs. However we can create a textbox in this report, use custom code and expression to display the custom error message. For more details, please refer to the following steps:
Go to Report Properties. Put the code below into custom code:
Public Shared a As Integer=0
Public Shared Function IsDate(d1 As String) as Integer
Try
FormatDateTime(d1)
Catch ex As Exception
a=1
End Try
return a
End Function
Change the parameter data type from Date to Text.
Change the filter expression from Parameters!ReportParameter1.Value to the following:
=IIF(Code.IsDate(Parameters!ReportParameter1.Value)=0,cdate(Parameters!ReportParameter1.Value),CDate("1/3/2013"))
Use the expression below to set the visibility of the tablix:
=IIF(Code.IsDate(Parameters!ReportParameter1.Value)=0,false,true)
Create a textbox with the expression below:
=IIF(Code.IsDate(Parameters!ReportParameter1.Value)=0,"","custom error message")
Hope this helps.
Thanks,
Katherine Xiong
Katherine Xiong
TechNet Community Support -
How to get call data entered at IVR from Jtapi?
Hi all,
I need help regarding retrieving data entered by caller at IVR to the agent desktop screen.
Setup is Avaya AES server with Jtapi service and Avaya Voice Portal.
Application is to be developed using Avaya Jtapi and required to show data entered/keyed in by customer at IVR to agent's screen pop, as soon the call lands to an agent.
I tried to find out API for that within Avaya Jtapi library, however couldnt find any suitable way to achive the requirement.
Pls suggest what could be the possible solution for this scenario.
Thanks,
AmitI would say to find a
[Avaya Jtapi|http://www.avaya.com/devconnect]
forum, and not a general Java forum. You are liable to get better and quicker answers. -
How to avoid losing data when communicat​e with high speed motor?
I connect with high speed servo motor via RS232. To avoid losing data. i thought to set receive buffer, only read the buffer if it collected all bytes. Is this possible?
Hi,
If you know the number of bytes you are trying to read, you can set a viRead call to return information once the particular number of bytes have been read. For more information on this, take a look at the KnowledgeBase article on a Serial VISA Read to read a requested number of bytes.
Even if you read before all bytes have been collected, you should not lose data. When the specified number of bytes are stored in the buffer, the viRead call will send the information to the program, and new data coming in will be stored in the buffer until the byte count is reached again.
I hope this helps,
Lauren L.
Applications Engineering
National Instruments -
How to fill values in the system matrix through code
hi
All
i want to fill the system matrix in the sales order in such a way that
Items will be filled in system matrix in the lost focust event of the Customer Code selection in the Sales order Document
how can i fill the system matrix through code
one thing that first column(ItemCode) of the system matrix column is a Icombbox type
Now i need to fill out item code using code
can any one suggest the answer
thanks in advancemadhu,
You need to catch the Validate event, when pVal.BeforeAction = False for form items 4 (CardCode) and 54 (CardName) of the Sales Order form.
Concerning the form's matrix, you can fill it but you cannot change it (you cannot change the ItemCode column into a ComboBox. Is is a EditText)
Fill a System matrix's Cell with the following code:
Dim oMatrix As SAPbouiCOM.Matrix = oForm.Items.Item("38").Specific
oMatrix.Columns.Item("ItemCode").Cells.Item(Row_Num).Specific.Value = "Item_Code"
Regards,
Vítor Vieira -
How to ristric the user when data enter in lov column.
Hi all,
i have one page,page having lov column and submit button.
here user select the value in to lov column and click on the submit button details ll be displayed.
but user did not select the value in to lov means user enter the value in manually and click on the submit button at that time lov window ll be open.so how to ristric the user.plz help me its very urgent.
Thanks
Seshu.Hi,
What is your requirement?
You want to validate value entered by user in LOV field or not?
If yes, then this the correct behavior.
In no, you can disable client validations. In this case the value entered won't be validated against the LOV vo and value will be stored in the vo attribute mapped to LOV bean.
Thanks,
Mukesh Uchaniya -
Hi experts,
i loaded a flatfile1 into an ODS and then into an infocube. Again i loaded another flat file2 ( which had the same records as well as few more records as first one) the same way.. when i look at the Infocube, some of the records have double the values. How do i avoid this.. can i go for delta load from ods to infocube..
all the above loads are fulupdate.
Also SDNers,
By full update do we get all the data again if we load from ODS even if we laoded previously.?
thanks
Dave
Message was edited by: Dave MarcusIf you go as Delta from ODS to Cube, ODS will take care in sending only the changed records and the new records.
see this link:
Re: Delta Processing in ODS
Also see:
ODS & Delta
Thanks,
Raj
Maybe you are looking for
-
Help with putting a logo on top of a photo as a web page heading
I am new to this and stuck with what i imagine is a simple problem. I need to replace a former name with a new one on a website. The old logo has also been changed. The page headings have been changed also. I have a logo scanned as a jpg but can re-s
-
Deleting programs with all containing files at once
how can i uninstall an application wich concists of many small files spreaded all over the harddisc?? Do i have to search for all those files separately?? Or is there a way to remove a program with all the files at once??? Does anyone know how see th
-
Hi , I have to use one variable's value into another program (in BADI). For that I am exporting that variable from main program and using IMPORT I am using into BADI. Code is shown below, FREE MEMORY ID 'REFPO'. EXPORT pa_doc2 FROM v_podoc TO MEMORY
-
Error "no special gl acct defined"
Hi, i am trying to make some payments to a vendor using transaction FB01 and posting keys 39/ XXXXXX with special G/L K and 29/ XXXXXX with special G/L L <b>i get an error "No special G/L acct defined for acct type K sp.G/L ind.L recon.acct x
-
I just opened Mail and the four emails that were in one of my three accounts' inboxes say that they have not been downloaded from the server and I should make the account online. This is only for those four inbox emails, not the same accounts' emails