How to get current session language ?
Hi,
I want to get the current session's language.
I'm using pageContext.getOANLSServices().toString() but its output is oracle.apps.fnd.framework.OANLSServices@f55137
Any ideas ?
Thanks
Hi,
Use the below code in CO for getting the Language.
pageContext.getCurrentLanguage();Regards,
Gyan
Similar Messages
-
How do I get current session language in the jsp page ?
I have a simple jsp page which I called from the iProcuremnt. I need to display the session language, which user select from preference/login page .
Here is my code snippet.
<%
WebAppsContext _ctx = null;
_ctx = WebRequestUtil.validateContext(request, response);
WebRequestUtil.setClientEncoding(response, _ctx);
Connection conn = ctx.getJDBCConnection();
String sql = "select fnd_global.org_id , 'FRC/US' from dual”
//fnd_profile.value('ICX_LANGUAGE') always get AMERICAN
_ps = _conn.prepareStatement(sql);
_rs = _ps.executeQuery();
out.println("The Org id is : " + corg + " , "Langage is : " + cLang);
%>
Thank you in advance.destination URI should have one more parametre, say lang IS ENG
MyTestPage.jsp?MODE=U&RLI={$RequisitionLineId}&LANG=ENGLISH
and get this param from url in jsp.
--Mukul -
How to get current locale / language
Hi,
I am trying to change the default startup settings for a CDE session, and I need to edit the file
/usr/dt/config/lang/sys.session
There are two possibilities:
/usr/dt/config/C/sys.session
or
/usr/dt/config/en_US.UTF-8/sys.session
How can I find out what is my current locale so that I can edit the correct file?
Also, I am troubleshooting the problem from a remote VNC connection (su to user and start vncserver). Will the locale from the VNC connection differ from the local X session?
Thank you in advance.The default locale is normally set in /etc/default/init , but you can normally view them by running the "locale" command, or simply by checking your environment using the "env" command.
7/M. -
Hi Experts,
We have installed UISKPI01 in SAP NetWeaver Gateway System for Fiori Analytical Apps (KPI modeler is necessary to model the KPI) but while trying to create and Save the Group, we are Getting an error in KPI Modeler as "{"customMessage":"failed to detect the sap language of the current session language","status":500}". Similarly, when we are trying to edit the existing KPI template and assigning the Variants and Evaluations, we are facing the same error as failed to detect the sap language of the current session language","status":500.
Any idea on above error?
Thanking you,
~ MahendraHello Mahendra,
Check if you have entries in the T002 table of SAP_SSB schema.
If not follow the steps mentioned in the admin guide of SAP Smart business to populate data.
This should resolve this issue.
Note: My assumption is that, you are accessing the KPI modeler in English Language.
Thanks,
Debasish -
How to get current view name on clicking device back button?
Hi,
iam wriing a function for handling device back button(in android) press in my app.controller.js .How to get current viewname when clicking device back button.
code samples will be helpful.
my app.controller.js looks like below
sap.ui.controller("com.opensap.App", {
onInit : function() {
document.addEventListener("deviceready", onDeviceReady, false);
onBeforeShow : function(evt) {
navButtonTap : function(evt) {
function onBackKeyDown(){
//alert("hai");
//sap.ui.getCore().byId("SalesDetail").app.backToPage("ProductList");
//sap.ui.getCore().byId("ProductList").app.backToPage("Dashboard");
//sap.ui.getCore().byId("SupplierDetail").app.backToPage("Dashboard");
function onDeviceReady(){
document.addEventListener("backbutton", onBackKeyDown, false);I somehow managed to find the solution
function onBackKeyDown(){
var app = sap.ui.getCore().byId("LoginDetail").app;
app.back(); -
How to get current row data in table control
Hi , expert ,
I am professional in oracle , but now I am a new guy in SAP ABAP .
I have a question in UI
How to get current row data and click pushbutton in table control to open next screen ?
I want to get the current data and open next screen to carry out detail detail .
Thansk for all your suggestion .GET CURSOR LINE SY-CUROW .
READ TABLE internal_table index SY-CUROW. -
How to get current version of safari. without having safari browser?
how to get current version of safari. without having safari browser?
I don't understand the question. Safari is a browser.
Can you elaborate on what your are trying to do that initiated the question? People may be able to come up with some other option that gets you working the away you want.
When you respond, please post the version of the Mac OS and the version of Safari you currently have. Otherwise, people are guessing and the quailty of help you get plummets. -
How to get HTTP session in Applcation Module IMPL file
Hi Guys,
Can any one tell me how to get HTTP session in Applcation Module IMPL file ?
thnksYou can, but that's not a best practice.
Re: How to reach HttpContext from model Project -
How to get current rowindex of clicked object in cr2008 preview control
hi
i want to get selected raw data when user click on crystal report 2008 preview control.
i can achieve using following code for particular row no.
Dim repReport as new ReportDocument
repReport.Rows(RowIndex).Item(ColumnIndex)
how to get current rowindex ?
Thanks
Sanjiv SharmaOnly way I can think of is to use the rowset controller from the InProc RAS SDK. Here is a snippet of a sample code on how to:
//Load the report
if (clientDoc != null) {
//create metadata structure
RowsetMetaData rowSetMetaData = new RowsetMetaData(); rowSetMetaData.setDataFields
(clientDoc.getDataDefinition().getResultFields());
Fields fields = rowSetMetaData.getDataFields();
String colName,colTypeName;
int colType, len;
Field field;
HashMap colNames = new HashMap();
HashMap colTypes = new HashMap();
for (int i = 0; i < fields.size(); i++) {
field = (Field) fields.get(i);
colName =field.getDisplayName(FieldDisplayNameType.description, Locale
.ENGLISH);
colNames.put("COL"+i,colName);
colType = getColTypeFromVariant(field.getType().toVariantTypeString());
len=field.getLength();
//Placeholder
//add column metadata to data structure or XML
Object colValue;
int rowCount=0;
if (getMaxRows() != 0) {
RowsetCursor rowsetCursor = clientDoc.getRowsetController(). createCursor
(null, rowSetMetaData);
//Setting the batch size to make sure that you get back all the
//rows by setting the batch size.
clientDoc.getRowsetController().setRowsetBatchSize (rowsetCursor
.getRowset().getTotalRecordCount());
//Getting the Results back starting from the first row
RowsetCursor resultCursor = clientDoc.getRowsetController(). createCursor(null,
rowSetMetaData);
resultCursor.moveTo(0);
while (!resultCursor.isEOF()) {
for (int i = 0; i < fields.size(); i++) {
colName=(String)colNames.get("COL"+i);
colTypeName=(String)colTypes.get("COL"+i);
colValue=record.getValue(i);
//Placeholder
//add row data to data structure or XML
resultCursor.moveNext();
For more details, consult the Report Application Server .NET SDK Developer Guide
Ludek
Follow us on Twitter http://twitter.com/SAPCRNetSup
Got Enhancement ideas? Try the [SAP Idea Place|https://ideas.sap.com/community/products_and_solutions/crystalreports] -
How to get Current row of ViewObject in the DoDML methode
Hi all
I have two ViewObject EmplyesView and DeptView
How to get Current row of ViewObject DeptView in the DoDML methode of EmplyesViewOK, we can play this game on and on...
I'll ask for a use case (http://en.wikipedia.org/wiki/Use_case) and you don't give any info we don't already know. After an other 10 posts we probably know what you real problem is and can give you the advice which you could have gotten in the fist place.
So please take some time and describe the problem as if you would ask your mother for help. Tell us how the data model is build and how the VO are related. Is there any input from an user involved? Which information from the other view do you need? How do you get to the doDML method? Is there a button in the ui involved?
Timo -
How to get transacted session in direct mode with jmsra adapter
Hi,
I use MQ 4.4u1 release with GF in EMBEDDED mode. I configured several connection factories with NoTransaction/LocalTransaction/XATransaction support. In my app I get a connection factory from JNDI tree, create connection/session/producer and send several messages to queue. Everything works fine when I don't use transactions. But, when I want to send messages in one transaction, the connection always provided to me non-transacted session. The session created via
Session session = connection.createSession(true, Session.SESSION_TRANSACTED);
request. I check the session transacted state and acknowledge mode right after i get it:
log.fine("Session: " + session + "; transacted: " + session.getTransacted() + "; ackMode: " + session.getAcknowledgeMode());
The log shows me that the session is not transacted and ackMode is 0 (DUPS_OK_ACKNOWLEDGE). If I try to commit the session after messages were sent I get the correct exception:
javax.jms.IllegalStateException: MQJMSRA_DS4001: commit():Illegal for a non-transacted Session:sessionId=3361979872663370240
Does anyone know how to get transactional session in direct mode?
Thanks, Denis.I mentioned LOCAL because I misread your post and thought you were suggesting that LOCAL mode behaved differently.
If you want to send messages in a transaction from within a Servlet then I think you're expected to use a UserTransaction: Here's an example that worked for me:
Connection connection = outboundConnectionFactory.createConnection();
Session session = connection.createSession(true, Session.SESSION_TRANSACTED);
userTransaction.begin();
MessageProducer producer = session.createProducer(outboundQueue);
int numberOfMessages = 10;
for (int i = 0; i<numberOfMessages; i++) {
Message message = session.createTextMessage("Hello world");
producer.send(message);
userTransaction.commit();
connection.close();I obtained the UserTransaction with this resource declaration:
@Resource(name = "java:comp/UserTransaction")
private UserTransaction userTransaction;The EJB spec explicitly states that local transactions aren't supported in EJBs; I haven't found such an explicit statement for Servlets but suspect that JMSRA is taking the same approach.
As for imq.jmsra.direct.disableCM property - this appears to disable connection pooling and from your post changes other behaviour as well. How did you find out about it (other than by examining the code)? As far as I can see this is not a documented feature and is not necessarily tested or supported. -
How to get current month and last month dynamically??
how to get current month and last month dynamically
like
month = getCurrentMonth();
lastmonth = getcurrentMonth() -1;
please help
thankshi :-)
/* depracated but can be still useful */
java.util.Date dtCurrent = new java.util.Date();
int month = dtCurrent.getMonth();
int lastmonth = dtCurrent.getMonth() - 1;
System.out.println("* " + month);
System.out.println("* " + lastmonth);
/* better to use this one */
Calendar cal = new GregorianCalendar();
int imonth = cal.get(Calendar.MONTH);
int ilastmonth = cal.get(Calendar.MONTH) - 1;
System.out.println("*** " + imonth);
System.out.println("*** " + ilastmonth);
regards, -
Hi,
does anybody know how to get IUser for the current user?
I know how to get current IUser from com.sap.security.api package:
IWDClientUser wdcu = WDClientUser.getCurrentUser();
IUser sapUser = wdcu.getSAPUser();
but I need to have IUser from com.sapportals.portal.security.usermanagement package.
Regards,
LadislavLadislav,
Try this:
Get the IUser uisng the API com.sap.security.api.IUser and store it in a variable, say <i>sapUser</i>.
Then,
// Convert the logged in user to old EP5 usermanagement API
com.sapportals.portal.security.usermanagement.IUser user = null;
try
com.sapportals.portal.security.usermanagement.IUser user = WPUMFactory.getUserFactory().getEP5User(sapUser);
catch (UserManagementException e)
e.printStackTrace();
Bala -
How to get current assigned participant id?
Hi mates,
This might be a basic questions, but useful for me :)
How to get current assigned participant id from screenflow? Or How to pass it as an argument from interactive activity?
Below is what I tried.
Participant.id or Instance.participant.id - returns login user id
ThanksHi,
Please correct me if I understood wrong.
You want to know whether an instance is assigned or not and if assigned then you want to fetch the assigned participant id.
If this is your requirement then please find the code below and make the necessary changes into it.
Write the following code in screen flow automatic activity but before that you need to pass the instanceid as argument to the screen flow.
In the process as well as screen flow layer make an instance variable instanceid as Int.
Then make an argument variable instanceidArg as Int in both the screenflow and process layer and map accordingly so that it will take the instanceid from process layer to the screen flow layer.
Assign instanceid = id.number; in process layer automatic activity but before the global interactive activity where you have maped the screen flow.
Write the following code in screen flow automatic activity.
logMessage("============= instanceid ==============" + instanceid); //instanceid is the id of the instance that you have passed from process layer.
ProcessService ps;
InstanceFilter instF = InstanceFilter();
ps.connectTo(url : Fuego.Server.directoryURL, user : "<userid>", password : "<password>"); //In studio the userid and password will be same
logMessage("Connected");
instF.create(processService : ps);
instF.searchScope = SearchScope(participantScope : ParticipantScope.ALL, statusScope : StatusScope.ONLY_INPROCESS);
//<ProessId Name> is the id of the process where you want to know the assighed participant id
instF.addAttributeTo(variable : VarDefinition.processid, comparator : Comparison.CONTAINS, value : "/" + "<ProessId>");
instF.addAttributeTo(variable : VarDefinition.INSTANCE_NUMBER, comparator : Comparison.IS, value : Int(instanceid));
Fuego.Papi.Instance[] instances = getInstancesByFilter(ps, filter : instF);
foreach (instance in instances) {
logMessage("Assigned ?: " + instance.participantId.empty);
logMessage("instance.participantId: " + instance.participantId);
ps.disconnectFrom();
Bibhu -
How to get current date for posting date
hi,
how to get current date for posting date ? any sample code ?
ThanksHi......
Use
Select getdate()
for current date.......
Regards,
Rahul
Maybe you are looking for
-
This just happened 1 or 2 weeks ago. I go to System Preferences > Date & Time, and it doesn't open. The quote below is the error. Please help me. Is this the right thread to ask? Where can I post this or report this? Process: System Preferenc
-
Is there any way i can leave a suggestion for apple products
i would like to know why are we as the customers of apple not given the option to switch between pc's and manage music,videos , etc.on to different itunes with our i phones in my paticular situation the iphone 5 i would like to know if its possible t
-
Cross-References/Hyperlink Options Greyed Out (CS5)
I want to use the Cross References feature in InDesign CS5. I go to Type > Hyperlinks & Cross-References. All of the options are always greyed out besides Convert URLs to Hyperlinks... I also go to Window > Type & Tables > Cross-References. All optio
-
iCloud symbol in settings does not appear, instead there is the one for MobileMe, what do I have to do or didn't do well? Thanks in advance
-
Trying to change my billing information