Need a small help in java String
I have a String SDFGDS and now I want to have the individual alphabets put into an array ...like a[1] = S; a[2] = D;
Please tell me how can I do that.
Your help is greatly appreciated.
Regards & Thanks
Call the String's toCharArray() method, eg.String text = "abcdefg";
char[] chs = text.toCharArray();
Similar Messages
-
Hi ppl,
i hav a code which has to do some actions on the strings retrieved from the database. The code is in java swings
I need to know, how do i check if there is a space between strings.
For eg Kevin Dcosta. (There is a space between Kevin Dcosta)
Please can someone provide me with the Java code for the same so tat i can append to my code. Or is there any readymade method in Java for the same??
Thanks
Divya..Hi,
Go thr StringTokenizer Class it will help u out!........place whatever string u r reading in pu those in stringtokenizer like
StringTokenizer str=new StringTokenizer(tmpmessage, " ");
while(readTokenizer.hasMoreTokens())
String name=readTokenizer.nextToken();
/****** do whatever the action u want to do*************8
} -
Hi Java Guru,
i hv problem getting all the list box value.I hv read many forum posted by others but solutions seem not working.
below got 2 files code. test.htm will show all list box value and when onsubmit will call list() to change list box all value to "selected" so test.jsp can receive all list box value.
unfortunately, i can receive the highlighted list box value only on test.htm.
i really need some help!!!!
thanx first.
test.htm
========
<FORM NAME="formName3" onsubmit="list()" ACTION="test.jsp">
<SELECT NAME="selectName" multiple onChange="onChange(this.form)" size="3">
<OPTION VALUE="1" SELECTED>PartNameA
<OPTION VALUE="2">B
<OPTION VALUE="3">C
<OPTION VALUE="4">E
<OPTION VALUE="5">F
<OPTION VALUE="6">G
</SELECT>
<SCRIPT LANGUAGE="JavaScript">
function list()
for(i=0; i < document.formName3.selectName.length; i++)
{document.formName3.selectName.options.selected = true; }
</SCRIPT>
<input type="submit" value="Submit" name="B1">
</form>
test.jsp
========
<%
String[] values2 = request.getParameterValues("selectName");
System.out.println("values length:" + values2.length);
if( values2 != null && values2.length > 0 )
for( int i = 0; i < values2.length; i++ )
out.print( "value " + i + ": " + values2[i] + "<br>" );
%>1. jsUnit -- JavaScript unit testing tool akin to JUnit.
http://www.edwardh.com/jsunit/
2. Venkman -- A surprisingly sophisticated JavaScript debugger.
http://devedge.netscape.com/viewsource/2002/venkman/01/
As for an editor that checks JavaScript syntax the only one I know of is SlickEdit but it is very expensive.
Intellij IDEA is supposed to have this feature in a future release. -
Need some urgent help with Java code...
Hello
i am taking a java class..beginner..and i am a dud at programming...
had a couple of questions ..how do make a program ignore negative
integer values,make it terminate when zero is entered instead of a number ,how should i calculate maximum minimum of integers..please help me..
thanks
daminiYou got some good advice from Java_Jay.
Here is a snippet I keep handy for console input and output. It doesn't do your home work but gives you a working example of getting numbers from stdin:
import java.io.*;
public class DemoKeyboardInput {
public static void main(String[] args) throws IOException {
// open keyboard for input (call it 'stdin')
BufferedReader stdin = new BufferedReader(new InputStreamReader(
System.in), 1);
// get input from the keyboard
System.out.print("Please enter your name: ");
String name = stdin.readLine();
System.out.print("Please enter your age: ");
String s1 = stdin.readLine();
System.out.print("Please enter the radius of a circle: ");
String s2 = stdin.readLine();
// perform conversions on input strings
int age = Integer.parseInt(s1); // string to int
double radius = Double.parseDouble(s2); // string to double
// operate on data
age++; // increment age
double area = Math.PI * radius * radius; // compute circle area
// output results
System.out.println("Hello " + name);
System.out.println("On your next birthday, you will be " + age
+ " years old");
System.out.println("Area of circle is " + area);
} -
I'm new to java used to program with C++. I need to know whether there is ques in java and if there is how to use them. and if not what is an alternative? please help
I'm new to java used to program with C++. I need to
know whether there is ques in java and if there is
how to use them. and if not what is an alternative?
please helpAre you asking about queues?
Java� Collections Framework
http://java.sun.com/j2se/1.5.0/docs/api/java/util/Queue.html -
Hi
I am a BW consultant working an MNC .. i need to learn ABAP .
I need to learn the Basic skills of ABAP
Writing Routines
writing ABAP programs
user exits
i need ABAP relavent to BW ..
can any one help me .. where can i get the good material . which is more easy to understand..explainatory
If any docs please forwd to [email protected]
are any links that will be gr8 tooo..
Thanks in Advance..
regards
AKhi
You can use these links...
ABAP in 21 days
http://cma.zdnet.com/book/abap/ch03/ch03.htm
http://help.sap.com/saphelp_40b/helpdata/en/4f/991f82446d11d189700000e8322d00/applet.htm SAP Online Help For Dictionary.
http://sappoint.com/abap/
for SAPscripts
For follg., refer http://www.henrikfrank.dk/abapuk.html
Please note that I do not offer any support for the examples !
ABAP objects and control technology
IDOC
SapScript
Performance tuning
BAPI Programming
Visual Basic Integration - Using the DCOM Connector and BAPI OCX (Only available in Danish)
JAVA and the SAP java connector
http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/abapindx.htm
for keywords
very useful link for all
http://www.sapgenie.com/abap/index.htm
http://www.sap-img.com/abap.htm
http://www.sapdevelopment.co.uk/tips/tipshome.htm
http://help.sap.com/printdocu/core/Print46c/en/Data/Index_en.htm
http://sap.ittoolbox.com/nav/t.asp?t=322&p=322&h1=322
http://sap.ittoolbox.com/nav/t.asp?t=448&p=448&h1=448
http://www.thespot4sap.com/
http://www.kabai.com/abaps/q.htm
http://www.geocities.com/mpioud/Abap_programs.html
http://www.sapgenie.com/abap/tips_and_tricks.htm
http://www.sapassist.com/code/d.asp?whichpage=1&pagesize=10&i=10&a=c&o=&t=&q=&qt=
For FAQ
http://www.sap-img.com/abap/more-than-100-abap-interview-faqs.htm
http://www.sapgenie.com/faq/abap.htm
BAPI-step by step
http://www.sapgenie.com/abap/bapi/example.htm
Weblog for receive email and processing it through ABAP
/people/thomas.jung3/blog/2004/09/09/receiving-e-mail-and-processing-it-with-abap--version-610-and-higher
For Logical database
http://help.sap.com/saphelp_46c/helpdata/en/9f/db9bed35c111d1829f0000e829fbfe/frameset.htm
very useful
http://help.sap.com/saphelp_46c/helpdata/EN/35/2cd77bd7705394e10000009b387c12/frameset.htm
Useful link to websites
http://www.hernangn.com.ar/sap.htm
Useful for background
http://www.sappoint.com/basis/bckprsng.pdf
http://help.sap.com/saphelp_nw04/helpdata/en/6f/08703713bf277ee10000009b38f8cf/frameset.htm
http://publib.boulder.ibm.com/infocenter/wbihelp/index.jsp?topic=/com.ibm.wbix_adapters.doc/doc/mysap4/sap4x41.htm
Table control in BDC
http://www.sap-img.com/abap/bdc-example-using-table-control-in-bdc.htm
For posting weblog,
/people/sap.user72/blog/2005/06/28/sdn-weblogs-making-it-easier
Dynamic Internal table -weblog in sdn
/people/subramanian.venkateswaran2/blog/2004/11/19/dynamic-internal-table
Smartforms
http://www.sap-basis-abap.com/sapsf001.htm
http://www.sap-press.com/downloads/h955_preview.pdf
http://www.ossincorp.com/Black_Box/Black_Box_2.htm
http://www.sap-img.com/smartforms/sap-smart-forms.htm
http://www.sap-img.com/smartforms/smartform-tutorial.htm
http://www.sapgenie.com/abap/smartforms.htm
How to trace smartform
http://help.sap.com/saphelp_47x200/helpdata/en/49/c3d8a4a05b11d5b6ef006094192fe3/frameset.htm
Workflow
http://www.sap-img.com/workflow/sap-workflow.htm
http://help.sap.com/saphelp_47x200/helpdata/en/a5/172437130e0d09e10000009b38f839/frameset.htm
For examples on WorkFlow...check the below link..
http://help.sap.com/saphelp_47x200/helpdata/en/3d/6a9b3c874da309e10000000a114027/frameset.htm
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/PSWFL/PSWFL.pdf
http://help.sap.com/saphelp_47x200/helpdata/en/4a/dac507002f11d295340000e82dec10/frameset.htm
http://www.workflowing.com/id18.htm
http://www.e-workflow.org/
http://web.mit.edu/sapr3/dev/newdevstand.html
ALV
http://www.geocities.com/mpioud/Abap_programs.html
Mail
http://www.geocities.com/mpioud/Z_EMAIL_ABAP_REPORT.html
http://www.thespot4sap.com/Articles/SAP_Mail_SO_Object_Send.asp
http://www.sapdevelopment.co.uk/reporting/email/attach_xls.htm
Sending mail in background or spool mail
http://www.sap-basis-abap.com/sapac018.htm
BOM Explosion
/people/prakash.singh4/blog/2005/05/15/explode-boms-in-enterprise-portal-using-htmlb-tree--part-1-abap
BOM
http://help.sap.com/saphelp_erp2005/helpdata/en/ea/e9b7234c7211d189520000e829fbbd/frameset.htm
http://help.sap.com/saphelp_erp2005/helpdata/en/d1/2e4114a61711d2b423006094b9d648/frameset.htm
http://www.sap-img.com/sap-sd/sales-bom-implementation.htm
http://www.sap-basis-abap.com/sappp007.htm
OLE
http://www.sapgenie.com/abap/ole.htm
http://help.sap.com/saphelp_46c/helpdata/en/59/ae3f2e488f11d189490000e829fbbd/frameset.htm
ALVGRID with refresh
http://www.geocities.com/mpioud/Z_DEMO_ALV_REFRESH_BUTTON.html
For language setting and decimal separator
/people/horst.keller/blog/2004/11/16/abap-geek-7-150-babylonian-confusion
Oracle queries
http://sqlzoo.net/
To format SQL
http://www.sqlinform.com/
SCOT settings
http://www.sap-img.com/basis/basis-faq.htm
Status Icon [ALV,Table Control,Tab Strip]
http://www.sapdesignguild.org/resources/MiniSG-old/from_develop/norm_status_icons.htm#positioning_4
ALV Group Heading
http://www.sap-img.com/fu037.htm
For multiMedia
/people/thomas.jung3/blog/2005/05/11/using-classic-activex-controls-in-the-abap-control-framework
Uploading LOGO in SAP
http://www.sap-img.com/ts001.htm
LSMW
http://www.sap-img.com/sap-data-migration.htm
http://www.sapgenie.com/saptech/lsmw.htm
http://sapabap.iespana.es/sapabap/manuales/pdf/lsmw.pdf
http://www.sap.info/public/INT/int/glossary/int/glossaryletter/Word-17643ed1d6d658821_glossary/L#Word-17643ed1d6d658821_glossary
OOPS ALV
OOPS - Events.
Editable ALV
Tree
TabStrip
Multigrid
Check this for basic concepts of OOPS
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/abap%20objects/abap%20code%20sample%20to%20learn%20basic%20concept%20of%20object-oriented%20programming.doc
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/alv%20grid/abap%20code%20sample%20to%20display%20data%20in%20alv%20grid%20using%20object%20oriented%20programming.doc
Tabstrip
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/alv%20grid/abap%20code%20sample%20for%20tab%20strip%20in%20alv.pdf
Editable ALV
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/alv%20grid/abap%20code%20sample%20to%20edit%20alv%20grid.doc
Tree
http://www.sapdevelopment.co.uk/reporting/alv/alvtree/alvtree_usrint.htm
General Tutorial for OOPS
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/an%20easy%20reference%20for%20alv%20grid%20control.pdf
Function Module
http://www.geocities.com/victorav15/sapr3/abapfun.html
My Links
Smartforms
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/ccab6730-0501-0010-ee84-de050a6cc287
https://sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/8fd773b3-0301-0010-eabe-82149bcc292e
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/3c5d9ae3-0501-0010-0090-bdfb2d458985
Table Control
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/table%20control%20in%20abap.pdf
regards. -
I tried to transfer my purchases from one iPod to another computer. BUT, came up a little window that said "You need to authorize....".
I checked a little option in the window that said, "Do not warn me again."
I regret that.
I need to see that little pop-up, how though?Hello there,
One option is to reset all the dialog boxes in iTunes in iTunes preferences. To do this, head to the Edit drop down menu in iTunes and choose Preferences. When the window pops up, head over to the Advanced tab. You will see an option that says "reset all dialog warnings:" with a button that says "Reset" next to it. Go ahead and click this button and restart iTunes. You should be good to go from there.
Hope this helps.
B-rock -
Hi
I had a form with many form fileds and now we are adding one input text field that should be numeric with 5 digits long and i need to validate this input for numeric and 5 digits long(if the user enters anything in this field or its ok with empty field also if not entered) field with jquery with out submitting form any help in this.
<input type="text" name="myID" >
Thanks.ColdFusion has these features built-in, so why not use those.
<cfform name="myform">
<cfinput type="text" name="zip" validate="regular_expression" pattern="^\d{5}" validateat="onBlur">
<cfinput type="submit" value="submit" name="submit">
</cfform>
If you don't want to define a custom regular expression as the validation pattern, check out the other options for the validate attribute.
http://help.adobe.com/en_US/ColdFusion/9.0/CFMLRef/WSc3ff6d0ea77859461172e0811cbec22c24-7f 51.html
-Fernis -
Need a small help form the apple support
Dears,
i bought the iphone from Vodafone when i was in india visiting and working for a period time, however the iphone locked only it works for Vodafone so i need to unlock it officially from Apple, what is the way to open it from Apple. please guide me to the right directionAccording to http://support.apple.com/kb/HT1937, Vodafone India does not unlock the iPhone. You will need to sell that phone and buy the phone sold in the country you are currently in.
-
Plzzzzzz i need a small help in database view
Hi i have created a database view on your instructions it was executed with small warnings but the values in that tables are not transfered to this database view while activating it was showing some warnings and after that i had tried to execute that i tried see the values in that but there are no values in the database view so what to do know please give me any suggestions
hi
we made this query by using this we are getting perfect output but by using this query the performance is going slow so thats why we want to create view in order to increase sever performance
SELECT ALIFNR AEBELN BVGABE BEBELN CNAME1 CNAME2 C~LIFNR
DMATNR DTXZ01
DWERKS DNETWR DMENGE DMWSKZ EKOSTL EPS_PSP_PNR
FROM ( EKKO AS A
INNER JOIN EKBE AS B ON BEBELN = AEBELN
INNER JOIN LFA1 AS C ON CLIFNR = ALIFNR
INNER JOIN EKPO AS D ON DEBELN = AEBELN
INNER JOIN EKKN AS E ON EEBELN = AEBELN )
INTO
CORRESPONDING FIELDS OF
TABLE RTAB_ALV WHERE B~VGABE = '2'.
thanks yar. -
Need a little help understanding java and /etc/profile.d/***
A few days ago I installed jre-6u10-1 and jdk-6u10-1 via pacman on my desktop machine; for the web plugin.
The packages installed in /opt/java/...
I later installed jedit, via pacman. It runs fine as it (/usr/bin/jedit) is hardcoded to look for java in /opt/java/...
Today, I installed jedit (pacman -S jedit) on my laptop which did not have any java installed.
Pacman automatically installed openjdk6-jre-6u10-1 as a prerequisite.
Openjdk installs to /usr/lib/jvm/..., therefore jedit fails as /opt/java... is non-existent.
I suppose Sun's java and the opensource version are installed in different locations to keep from overwriting each other.
I could easily edit /usr/bin/jedit to point to the openjdk location and it would work.
But I'm a little uncertain of the following three files:
Sun's java installs /etc/profile.d/jre.sh and /etc/profile.d/jdk.sh
which do the following (respectively):
export PATH=$PATH:/opt/java/jre/bin
if [ ! -f /etc/profile.d/jdk.sh ]; then
export JAVA_HOME=/opt/java/jre
fi
and
export J2SDKDIR=/opt/java
export PATH=$PATH:/opt/java/bin
export JAVA_HOME=/opt/java
The opensource java package installs /etc/profile/openjdk6.sh
which does the following:
export J2SDKDIR=/usr/lib/jvm/java-1.6.0-openjdk
export J2REDIR=$J2SDKDIR/jre
export JAVAHOME=/usr/lib/jvm/java-1.6.0-openjdk
#export CLASSPATH="${CLASSPATH:+$CLASSPATH:}$J2SDKDIR/lib:$J2REDIR/lib"
So I am left with a few options:
1. edit /usr/bin/jedit to look in the opensource location
2. edit /usr/bin/jedit to use the $J2SDKDIR variable when looking for java
3. update the $PATH via /etc/profile.d/openjdk6.sh to include java's location
I think all three methods would work, but I have limited experience with java and would like some input as to which proposed solution is the best going forward.
What methods are other java apps using to find java?
Thanks
(edit: more descriptive title)
Last edited by cjpembo (2008-11-11 04:24:47)I think the best option would be to ask the maintainer to modify the jedit-bin file, and have it launch
$J2SDKDIR/bin/jre/java cp $CP -Djedit.home="/usr/share/jedit" -mx${JAVA_HEAP_SIZE}m org.gjt.sp.jedit.jEdit $@
That way, it should work with both java implementations (completely untested, btw.) -
Hi,
I need small help in sql*loader.I get data-files which has a particular identified on the 1st record( header ), based on which I've to load a constant for the 1st column of every row. How do I set in the control file.
Appreciate if someone can give me directions on this.
Thanks in advance,Hi again!
I hope that a little shell script will do the thing for you.
1.) Create the following BASH-Script
#!/bin/bash
export CUSTNO=""
export CUSTNO=$(awk -F"," '{print NR " " $3}' datafile.csv | grep 1 | cut -d" " -f2)
sed -i 's/#x#/'$CUSTNO'/g' controlfile.datI've use datafile.csv as the name of the datafile to load and controlfile.dat as the name of your controlfile. Please change this to fit your needs.
This script looks for the occurrence of your constant value and stores this value in the variable CUSTNO. Then it look for a string #x# in your controlfile and changes #x# to the value of CUSTNO.
So in your controlfile there should be a line for custno like that:
custno CONSTANT '#x#'This line will be replace in your example to:
custno CONSTANT '35642'To get this to work I assume that:
1.) Your constant value is always at the third position in the header of your datafile.
2.) You've made the change with #x# in your controlfile.
I hope that this is really usefull to you.
Best Regards
Florian W. -
Need flash player 8 and java script enabled to play videos on ipad, need help please.
need flash player 8 and java script enabled on my ipad in order to view videos. please help.
iPads do not directly support Flash.
You can look for Flash Browsers in the App store for some options to try. Support is not 100%, but maybe one may work for you. Browsers like Puffin, Skyfire, Photon etc...
IPads do fully support JavaScript. Just make sure its turned on under Settings->Safari->Advanced->JavaScript.
If you require Java, which is completely different to JavaScript, again there are some browsers in the App store that support it. Search for "Java browsers" in the store. -
i Need some help in Java Script,
am using the following code :
<script type="text/javascript">
var newwindow;
function poptastic(url)
newwindow=window.open(url,'name','height=300,width=400,left=100, top=100,resizable=yes,scrollbars=yes,toolbar=yes,status=yes');
if (window.focus) {newwindow.focus()}
else {newwindow.close()}
// if (window.focus) {newwindow.focus()}
</script>
In HTML,
thWorld Environment
Day, June 5<sup>th</sup>,2005
Am using onmouseover event, so that when my mouse in on the link, popup is opened....and when my mouse is out of the link, the new window should b closed....
but according to the above code, the new window is opened but have to close it manually....
Is there any other way to close the popup when my mouse is out of the linkPrawn,
This is not really a good way to make friends. With the cross posting and the posting in a wrong forum anyway thing you have going.
Please kindly take your question to an appropriate JavaScript forum.
Have a happy day.
Cross post from http://forum.java.sun.com/thread.jspa?messageID=3797201 -
Need HELP in JAVA ( client /server application )
hi there ,
I need the following codes in java for my client/server application . which i can use to perform certain function on another computer on LAN. This is part of my semester project . I would really appreciate if any one can help me
->Open/close the CD-ROM once or in intervals (specified in seconds).
->Swap mouse buttons the right mouse button gets the left mouse button's functions and vice versa.
->Start optional application.
->Play optional sound-file.
->Point the mouse to optional coordinates.
->Shutdown the system, logoff the user etc.
->Mouse can be controlled on the target computer with remote mouse.
->Keys (letters) on the keyboard can be disabled.
->Increase and decrease the sound-volume.
->Listen for keystrokes and send them back to you!
I would really appreciate if some1 can help me find these codes in java
thanx
Alamzaib Shafi
[email protected]Dude, if you did your own homework once in a while you'd be able to handle your own semester project. I hope you fail your class and get kicked out of the program. One less idiot with a diploma competing with us hackers for the tech jobs.
You are indeed a most worthy recipient of my unemployed angst.
Maybe you are looking for
-
Counting rows when subtracting several slicer options from another
Hi Everyone I am trying to count the number of rows in a pivot table/chart that equal the value of one slicer value minus other slicer values. I don't know if you can use countrows for this, but I tried countax and I am getting an error for "comparis
-
How do I uninstall an App in SnowLeopard ver: 10.6.8
I downloaded and installed an App Twice like a dummy! How do I uninstall one of these. I tried moving to trash but recv'd error saying " could not move to trash cause app was OPEN"! Dunno how to close? I just want it gone, huh! Also is there a utili
-
No iMessages after iOS 7.0.4 on iPhone 5s
Hi. Is anyone else experiencing the same issue? I have recently bought a brand new iPhone 5s. I upgraded yesterday to ios 7.0.4. It wiped my phone back to factory settings via iTunes! I reinstalled from a save though. Yesterday I also put in a replac
-
Hi All, I'm using PCUI Application CRMD_BUS2000111,BlView=SLS_ISU to create an opportunity. I see that when we call this PCUI it has all the fields grayed out and I need to click on New->opportunity to be able to edit the fields(create an opportunity
-
Was having issue with original 8G iphone showing 3.5G of "other" info
Was having issue with original 8G iphone showing 3.5G of "other" info stored on phone. I use multiple computers and at times sync with both and sync using mobileme account. After deleting extra text msg, emails, clearing history and cache in safari a