How to: set the time zone on a new event before adding it to the calendar?

I want to add a new event to the calendar, but when I do gets set to a time zone from the casablanca time which means GMT, I want to solve it the current time zone of users.  What is happening now is that if the user manually changes the time zone then the start time of the event changes too.

Here is my code so far:

EventList _eventList = null;
                try{
                    _eventList = (EventList)PIM.getInstance().openPIMList(PIM.EVENT_LIST, PIM.READ_WRITE);
                }catch(PIMException e){
                    Dialog.inform("PIMException : " + e.getMessage());
//                  return false;
                }

                BlackBerryEvent bbEvent = (BlackBerryEvent)_eventList.createEvent();
                java.util.Calendar cal = java.util.Calendar.getInstance(); 

                long start = cal.getTime().getTime();
                if (_eventList.isSupportedField(Event.START)) {
                    bbEvent.addDate(Event.START, 0, start);
                }
                if (_eventList.isSupportedField(Event.END)) {
                    bbEvent.addDate(Event.END, 0, start + 3600000);
                }
                if (_eventList.isSupportedField(Event.SUMMARY)) {
                    bbEvent.addString(Event.SUMMARY, 0, title);
                }
                if (_eventList.isSupportedField(Event.LOCATION)) {
                    bbEvent.addString(Event.LOCATION, 0, address+", "+city);
                }
                if (_eventList.isSupportedField(Event.)) {
                    bbEvent.addString(Event.LOCATION, 0, address+", "+city);
                }
                Invoke.invokeApplication( Invoke.APP_TYPE_CALENDAR, new CalendarArguments(CalendarArguments.ARG_NEW, bbEvent) );
//

How can I set the time zone before calling Invoke.invokeApplication?

OK, never mind, my Simulator has been updated with the different time zone, I thought he would pick uop, the right one.  Once I manually put itt o the right zoneit works as expected today.

Tags: BlackBerry Developers

Similar Questions

  • How to set the calendar tasks?

    I want to put a task based on the following conditions,

    1) run on each week (Monday to Friday) at 10:00

    2) run only on the following months: between March and November

    Anyone have any suggestions on how to plan this work in XP?

    Thanks in advance for your suggestions

    Hello

    You can check the link below to create the scheduled task in Windows XP.

    How to schedule tasks in Windows XP

    http://support.Microsoft.com/kb/308569

  • How to set the time of the wamp Server?

    Downloaded the latest version of Wamp (Apache 2.2.11, PHP 5.3.0 MySQL 5.1.36)

    Server time is 5 hours later than my time local (America, Chicago)

    Where can I change the settings for time?

    Thanks for your help,

    -Jim Balthrop

    This might help...

    p http://www.dedyisn.net/2009/02/How-to-Setting-default-time-zone-in-Apache-Webserver-for-pH.

    --
    Lawrence Cramer - * Adobe Community Professional *.
    http://www.Cartweaver.com
    Basket for Adobe Dreamweaver
    available in PHP, ASP and ColdFusion

    Stay updated - http://blog.cartweaver.com

  • How to set the time stamp for incoming mail?

    How to set the time stamp for incoming mail?  I have windows vista. I use hotmail/windows live email. My computer has the time is set correctly. My e-mail timestamps incoming messages 7 hours a head of real time. Example: it is now 09:48. A new email is stamped as to settle at 16:48. How can I fix it? Note: the computer is correct.

    Thank you
    Laura
    2.13.2012

    If you mean the customer of email Windows Live Mail, the time stamp on messages is governed by your time zonesystem. Right-click on the clock in the lower right of the screen and select CONFIGURATION... Change your time zone, and then set your clock at the present time.

    If you are talking about the Windows Live Hotmail service, the time zone (s) used are those contained in your account data. Reach
    https://account.live.com/EditProf.aspx
    and change the time zones for the good...

    Windows Live programs and services have their own forums for support at the Windows Live Solution Center. Please address any questions you may have about Windows Live Mail to one of the forums on the right side of this page. For Hotmail, forums and responses are available via this page.

    Noel

  • How to set the time that my screen stays on?

    How to set the time that my screen lights up.  I have an iPod Touch 6?

    Settings > general > auto-lock

  • How to set the time between slides in a slideshow (iPhoto, el capitan)

    How to set the time to say - 5 seconds or 20 seconds - between slide show photos in iPhoto. I use el capitan.

    See the Settings button at the bottom right of the toolbar (at the bottom of the slide show). Click on it and you have a small window with two tabes, refers to all the slides, the other to the selected slide. You can make your choice

  • How to set the date and time on my HP Officejet pro 8600 more?

    How to set the date and time on my HP officejet pro 8600 more?  It just on a printed journal Jan-oo-oo fax shows 00:00 AM.  There are no instructions on how to change this.  I need proof that I sent a fax to a certain date and time.  Help, please.  Thank you

    Hello

    Below are the steps to set the Date and time for your device:

    1. On the Control Panel, press the right arrow key ( ), press Setup ( ).

  • How to set the Date and time on a remote target in Measurement & Automation Explorer (MAX)?

    Hello

    I'm trying to follow the steps described in the following link:

    How to set the Date and time on a remote target in Measurement & Automation Explorer (MAX)?

    It is said

    The software on the target currently supports only the time zoneand deletes the old files?

    I need set the date and time

    and remove all the old unwanted files

    the calendar was gray does not allow me to change the current date.

    Anyone know how to change

    Hi all!

    According to this the below Knowledge Base article, Remote Configuration System Support must be installed on the target for time settings to change in MAX.

    http://digital.NI.com/public.nsf/allkb/FAB0EC4D6E5EE0F386257738005733A3?OpenDocument&MeTC=max_MAXDat...

    If you don't know what version of the system supported remote Configuration software that you have installed on your device target, it is likely that it is not yet installed. Add this software by clicking below your target to the MAX software option and selecting "Add/Remove Software". This is where you will install the System Configuration Remote Support software.

    Please let us know if you have any questions!

  • How to set the date and time hp7500a wide

    How to set the time and day there is no im the screen of the printer option

    I have re installed and it showed as you say the preferences... Thank you

  • How to set the date and time on an hp j5780?

    I need to know how to set the date and time on an HP j5780!

    Help!

    Thank you very much, we did it!

    WY

  • How to set the path of the report in a plugin for model

    I'm trying to figure out how to set the path of the report in a plugin process model. I can't find a way to have access to it. It seems this would be a reasonable thing to do since the plug-ins are for the treatment of the results. Does anyone know how to do this? We generally use the sequential process model, but I try to keep my plug-in as independent as possible.

    Thank you.

    If I understand correctly, you want your plug-in, when enabled, change the settings of all other instances of the report OR plugin as their reports share the same directory that your plug-in is configured to use.

    If so, your plug-in can access and change the settings of all other instances of plugin. All instances are passed to all the points of plugin entries in the subproperty of the plugins of the ModelConfiguration parameter table. You can browse this table. Any element of the array with an equal to "NI_ReportGenerator.seq" Base.SequenceFilename is an instance of the report OR plugin. Its report options are stored in the element under PluginSpecific.Options.

    You can change the report options to what you want. Note that the recall of the ReportOptions model is called from template-plugin Initialize entry point, then you might want to ensure that your changes are applied after that, so they are not replaced. To do this, you could make your changes in the Initialize entry point of your plugin and make sure your plugin runs last. To rotate the last, you can set the FileGlobals.ModelPluginComponentDescription.Default.Base.RunOrder in your file of plug-in with a value greater than 0, for example 1.0 (see Help for TestStand > Fundamentals > process template Architecture > plug-in for the model process Architecture > Structure of the plugin sequence files > plugin model of entry Points > Order Execution of Point of entry at run time).

  • How to set the voltage on a 3.3 volt NI 9237 module?

    Hello

    How to set the voltage on a 3.3 volt NI 9237 module?

    The voltage is now at 2.5 volts.

    This is my first time with this camera.

    This set of MAX or are there jumpers?

    I want the value of the excitation voltage at 3.3 Volts and do not change.

    The NI 9237 is a NEITHER cDAQ-9172.

    Thank you

    Bill

    Hi POBA,.

    This can be set to your programming environment.  For example, LabVIEW Signal Express, a task of MAX, or a DLL call in a text-based environment.  You want to create a strain, tension Custom with excitement, or any bridge based task in any environment.

    "" "In MAX, right-click on your device and choose create a task" acquire signals "analog input"...

    "" "In LabVIEW, place a DAQ Assistant" acquire signals "analog input"...

    "" "In Signal Express, add a step for Acquire" DAQmx Acquire"analog input"...

    In any C language based, you will want to call a function such as: DAQmxCreateAIVoltageChanWithExcit, DAQmxCreateAIStrainGageChan, DAQmxCreateAIBridgeChan

    You can then specify the Source of Exictation to be internal to 3.3V.

    Best,

  • How to set the timeout of read when using channelReader.ReadWaveform?

    I'm using a USB-6210/a. data acquisition, and it works fine until I have to take a longer than 10 s waveform.

    When I take a longer than wave form, I get the error 200284, "some or all of the requested samples are not yet acquired.  To wait for the samples become available use longer read timeout... »

    No problem, I thought, I'll just put a longer period.  I searched through the documentation, and the timeout only I found was the watchdog timeout.  When I wanted a longer value, I get code 200452 State - specific property is not supported by the device or is not applicable to the task.

    I use the code in the example AcqVoltageSamples_IntClk.2008 .net with c# in Visual Studio 2008, .net 3.5 sp1.

    How to set the timeout so that ReadWaveform() is not the time?

    Here is the code:

    privateAnalogMultiChannelReaderchannelReader;

    privateAnalogWaveform awf;

    publicList GetWaveForm()

    {

    Try

    {

    Task getWaveform = newTask();

    getWaveform.AIChannels.CreateVoltageChannel (Channel,"", TerminalConfiguration, RangeMinimum,

    RangeMaximum, AIVoltageUnits.Volts);

    getWaveform.Timing.ConfigureSampleClock ("", SampleRate, SampleClockActiveEdge.Rising,)

    SampleQuantityMode.FiniteSamples, NumSamples);

    getWaveform.Control (TaskAction.Verify);

    channelReader = new AnalogMultiChannelReader (getWaveform.Stream);

    AnalogWaveformdata = channelReader.ReadWaveform (NumSamples);

    AWF = data [0];

    samples As new List();

    for (inti = 0; i)

    returnsamples;

    }

    catch (DaqExceptionexception)

    {

    MessageBox.Show (exception. (Message);

    }

    List of l = newList();

    return l;

    }

    Thank you

    Curt

    Hi Curt,.

    Here is a Knowledge Base that can help you to set the timeout setting in your code:

    The property using Timeout of DAQmx task in Visual Studio

  • How to set the storage space allocated to the restoration of the system to 200 MB?

    Could you tell me how to set the maximum storage limit to 200 MB?

    Whenever I have delete system restore points, my hard disk free space increases about 10%.  About a week or so later, it's back to where it was before I deleted the restore points.

    It is very important for me because I am sure that storage space is set too high.

    Hello

    See the "BOLD" marked links with more information to help.

    Phantom memory also holds your restore VSSadmin points it defines parameters.

    How to create a Vista System Restore Point
    http://www.Vistax64.com/tutorials/76332-system-restore-point-create.html

    How to make a Vista system restore
    http://www.Vistax64.com/tutorials/76905-System-Restore-how.html
    How to turn System Restore on or off in Vista
    http://www.Vistax64.com/tutorials/66971-system-restore.html

    Adjustment of the amount of disk space, System Restore uses for restore points
    http://bertk.MVPs.org/html/diskspacev.html

    How to change how much Space System Restore can use
    http://www.Vistax64.com/tutorials/76227-system-restore-disk-space.html
    http://www.Petri.co.il/change_amount_of_disk_space_used_by_system_restore_in_vista.htm

    ShadowStorage vssadmin commands
    http://TechNet.Microsoft.com/en-us/library/cc755866 (WS.10) .aspx
    http://technet2.Microsoft.com/WindowsServer/en/library/89d2e411-6977-4808-9AD5-476c9eaecaa51033.mspx?mfr=true

    Guide to Windows Vista system restore
    http://www.bleepingcomputer.com/tutorials/tutorial143.html

    Expiration errors occur in Volume Shadow Copy service writers, and shadow copies are lost during
    backup and at the time when there are high levels of input/output
    http://support.Microsoft.com/?ID=826936

    A good utility:

    Explorer of the shadow - free
    http://www.ShadowExplorer.com/

    I hope this helps.

    Rob Brown - Microsoft MVP<- profile="" -="" windows="" expert="" -="" consumer="" :="" bicycle="" -="" mark="" twain="" said="" it="">

  • How to set the key numb to activate at startup

    How to set the key numb to activate at startup on computer laptop gateway running windows 7?

    Original title: numb locking button

    Hello Wan,

    Thanks for the quick response. We appreciate your time and your efforts.

    By default the NUM LOCK status is the same as it was before you shut down the computer properly. If it is on when you shut it down it will be on when you turn on the computer again.

    A few users have solved this problem by disabling fast boot option in the BIOS (Basic Input Output System). I would ask disable youFast Boot to the BIOS and check if that helps.

    For more information about how to disable Fast Boot in the BIOS, I would ask you to contact the manufacturer of the system.

    Note:

    BIOS change / semiconductor (CMOS) to complementary metal oxide settings can cause serious problems that may prevent your computer from starting properly. Microsoft cannot guarantee that problems resulting from the configuration of the BIOS/CMOS settings can be solved. Changes to settings are at your own risk.

    Hope the helps of information provided. Let us know the results and do not hesitate to post on the Microsoft Community, in case you have problems when you are working on Windows.

Maybe you are looking for

  • Availability of updates of the iPhone 4S

    How long even the new software updates that will be released for iPhone 4S?

  • No valid guarantee in India

    Dear Sir/Madam, I bought a laptop Toshiba R630-14 t of one of your authorized dealers of Gulf, Achiever computers LLC, Ak Ain Centre, Dubai on 20 February, 2011 empty no. Bill R-5876 paying AED 3 350. At the time of the purchase, I was informed by th

  • Upgrade processor?

    I have a Compaq Presario CQ-60410us, and I was wondering if I could spend my processor? I was looking at this one: -http://www.amazon.com/INTEL-MOBILE-FSB1066-UFCPGA8-SOCKET/dp/B0030C7DUA/ref=pd_sim_sbs_e_6 Can I put? Thank you PS Also the amount of

  • get the Application Module during the invocation of Taskflow delimited

    Hello dear developers,I have a filter that maps just before the Faces Servlet and fill some attributes in the HttpSession before it proceeds with the request[...]If (_clientUser! = null & &! _clientUser.isEmpty ()) {}session.setAttribute (CLIENT_USER

  • You Tube will not accept my .avi download?

    My project file name is: Adobe Premiere Elements auto save\cycle 72 re - 5.prel.  It's a film about the bike and everything if the chronology is .avi 'You Tube' will accept .avi but my file has PREL tacked on the end. How can I change that to be acce