You Are Here:

Community: Developer Discussion Boards

#1 Old Payment method in midlet ?? - 2009-05-11, 09:15

Join Date: May 2009
Posts: 2
Noor Aldoja
Offline
Registered User
Hi,
Can any one help me with my midlet ?!!

If i want the user to select the method of payment: Visa or Mastercard

How can i do this , if i want it to work as a real payment?

I've made a list , and initialized it in the constructor:
Quote:
lstPay = new List ("Payment",List.EXCLUSIVE);
lstPay.append("Visa", null);
lstPay.append("Master card", null);
and i've created a method called : Payment()


Quote:
public void Payment ()
{
lstPay.addCommand(cmdBack);
lstPay.addCommand(cmdPay);
lstPay.addCommand(cmdExit);
lstPay.setCommandListener(this);
display.setCurrent(lstPay);
}
What are the other things that i have to provide??

Thanks in advance,,
Reply With Quote

#2 Old Re: Payment method in midlet ?? - 2009-05-11, 13:49

Join Date: Jun 2007
Posts: 534
Location: Mumbai
Send a message via Yahoo to prakash.raman
prakash.raman's Avatar
prakash.raman
Offline
Super Contributor
Hi Noor, Welcome to forum. I think this is first time u developing on j2me. Well You need to implement CommandAction() and it will be called when and command is selected(as you have already set the Commandlistener).Now when the 'cmdPay is selected u have to check which item in lstPay is currently focused that is "visa" or "Master card", and then depending on that u have to proceed further.

PS: Refer to java doc for j2me, it explains methods properly. u can find that in Wireless tool kit must have installed.


au revoir
Prakash Raman
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules

You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Forum Jump
Similar Threads
Thread Thread Starter Forum Replies Last Post
j2me Midlet Verification/Validation Problem Nikolaos Mobile Java Networking & Messaging & Security 5 2008-06-16 17:31
Opening connection to the secure element fails when restarting the midlet. tfroidcoeur Near Field Communication 6 2007-08-24 09:38
How can a MIDlet know it is invoked by sms or manually? younflancy Mobile Java Networking & Messaging & Security 1 2007-07-31 15:28
How can a MIDlet know it is invoked by sms or manually? younflancy Mobile Java General 2 2007-07-31 15:21
Methods, that take lots of space doctordwarf Mobile Java General 4 2003-07-30 12:05

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia