DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world
  • submit to reddit
Tinu Awopetu07/27/09
34712 views
5 replies

NetBeans IDE 6.7.1 with JavaFX Now Available for Download!

The NetBeans Team is pleased to announce the release of NetBeans IDE 6.7.1, which supports the latest JavaFX SDK. Download NetBeans 6.7.1 (A JavaFX-only download bundle is also available.) NetBeans IDE 6.7.1 is an update to NetBeans IDE 6.7 and includes the...

Rick Ross02/14/08
13979 views
16 replies

Welcome to DZone's new IndicZone community for Indian IT Pros

Let me welcome all of you to the new DZone community for one of the most important and fastest growing groups in the worldwide IT scene: Indian developers and IT professionals. No matter where you look, if something interesting is happening on the IT and...

Interact Intran...10/30/14
199 views
0 replies

Considering Your Collaboration and Knowledge Management as a Freemium Model

Freemium has become a popular model throughout software, from mobile apps and games which are free to download and then charge you to hasten progress or receive exclusive prizes, through to enterprise software which gives free access for a set period of time, for example you can trial Interact for 30 days for free and then decide if you wish to purchase it on a subscription basis.

Adi Gaskell10/30/14
151 views
0 replies

When good news isn’t welcome on social media

I wrote recently about some new research that explored the sharing of good news. The study wanted to explore the hypothesis that those around us would love to hear the exciting and wonderful things we have to share.

Christopher Blake10/30/14
465 views
0 replies

Digital Disruption - Sad but even Google isn't going far enough with their new "Inbox that works for you"

Google is someone that I have associated with rapid innovation and positive digital disruption in the past, and on the surface I was quite excited to read about their 'reinvention' of their inbox and email.

Robert Reeves10/30/14
217 views
0 replies

Your Job is to Manage, Automate, and Improve - So, Why Are You Only Doing the First Part?

No matter what position you have in IT, you can distill your job down to three tasks - Manage, Automate, and Improve.

Anshul Mittal10/30/14
139 views
0 replies

Resuable BPEL Subprocesses in Oracle SOA 12c

Oracle SOA Suite provides a subprocess extension to BPEL. A subprocess is a fragment of BPEL code that can be reused within a particular processor by separate processes. BPEL process code reusability, which reduces the need to create the same activities multiple times to perform the same tasks. Subprocesses are only supported with BPEL version 2.0. There is no support with BPEL version 1.1. Subprocesses cannot be shared between multiple composites.

Julia Wunder10/29/14
21 views
0 replies

Jelastic Version 2.5 Released: Automatic Horizontal Scaling, Multiple Nodes of Different Middleware Layers, Improved and Extended Marketplace

Jelastic, Inc., the first company that combined Unlimited PaaS (Platform-as-a-Service) and IaaS (Infrastructure-as-a-Service) in one solution, announced today a new Jelastic version 2.5 with support for multiple nodes of different stacks, automatic horizontal...

public class ThreadProc implements Runnable {

	boolean isRunning = true;
	Workbook testWorkbook;
	Random r = new Random();

	public ThreadProc(Workbook workbook)
	{
		this.testWorkbook = workbook;
	}

	public int randomNext(int Low, int High)
	{
		int R = r.nextInt(High-Low) + Low;
		return R;
	}

	public void kill()
	{
		this.isRunning = false;
	}

    public void run(){

    	while(this.isRunning)
    	{
            int row = randomNext(0, 100);
            int col = randomNext(0, 10);

            String s = testWorkbook.getWorksheets().get(0).getCells().get(row, col).getStringValue();

            if (s.equals("R" + row + "C" + col)!=true)
            {
                System.out.println("This message box will show up when cells read values are incorrect.");
            }
    	}
    }
  }


//........MainActivity.java........
//.................................
import java.io.File;
import java.util.Random;

import android.app.Activity;
import android.os.Bundle;
import android.os.Environment;
import android.view.Menu;

import com.aspose.cells.CellsHelper;
import com.aspose.cells.IWarningCallback;
import com.aspose.cells.WarningInfo;
import com.aspose.cells.WarningType;
import com.aspose.cells.Workbook;

public class MainActivity extends Activity {

@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
		
try{
    Workbook testWorkbook = new Workbook();
    testWorkbook.getWorksheets().clear();
    testWorkbook.getWorksheets().add("Sheet1");

    for (int row = 0; row < 100; row++)
        for (int col = 0; col < 10; col++)
            testWorkbook.getWorksheets().get(0).getCells().get(row, col).setValue("R" + row + "C" + col);

    //Commenting this line will show a pop-up message
    testWorkbook.getWorksheets().get(0).getCells().setMultiThreadReading(true);

    ThreadProc tp = new ThreadProc(testWorkbook);

    Thread myThread1 = new Thread(tp);
    myThread1.start();

    Thread myThread2 = new Thread(tp);
    myThread2.start();

    Thread.currentThread().sleep(5*1000);
    tp.kill();
}
		catch (Exception e)
		{
			e.printStackTrace();
		}
	}

.........

}

John Walter10/29/14
4462 views
0 replies

Dev of the Week: Michael Hunger

Every week here and in our newsletter, we feature a new developer/blogger from the DZone community to catch up and find out what he or she is working on now and what's coming next. This week we're talking to Michael Hunger, Neo4j Developer Advocate and author of our upcoming Neo4j Refcard.

John Walter10/29/14
5686 views
0 replies

The Best of DZone: Oct. 22 - Oct. 29

If you missed anything on DZone this week, now's your chance to catch up! This week's best include navigating the DSL Jungle, a look at Google Analytics, a tutorial for updating your legacy code, and more.

Kevin Daly10/29/14
1130 views
0 replies

Don’t Expect Female Candidates to “Geek Out” With You When You Are Interviewing Them

Why are there not more women in software development? What can we do to improve this?

Illya Pavlichenko10/29/14
185 views
0 replies

Perfection Game + SSKML Retrospective

This article describes in detailes how to conduct a Retrospective created by combining two well-known formats "Perfection Game" and "Stop/Start/Keep/More/Less". Lots of images precise facilitation instructions will help you to understand how to use it during your next Sprint Retrospective.

Interact Intran...10/29/14
262 views
0 replies

What happened at Interaction Intranet Conference 2014

The largest intranet conference in Europe kicked off with what is fast becoming a tradition of the conference – a video of Interact’s CEO Nigel Danson’s children. Their Oscar worthy performance showcases time wasting in organisations with repetition being one of the biggest culprits, begging the question “is it time for a social intranet?”.

Adi Gaskell10/29/14
433 views
0 replies

What ignites the fire of innovation within an organization?

Innovation is hard. I don’t think anyone really disputes that. It often makes the innovator rather unpopular amongst their peers, and there tends to be a well established army willing to fight tooth and nail to preserve what already is rather than plump for the uncertainty of what might be.

Christopher Blake10/29/14
264 views
0 replies

China Bank Phillipines adopting social business

Good news on innovative approaches should be retold. So here it is.

Franck Wolff10/28/14
32 views
0 replies

Beyond JSON: Spearal 0.2.0 Released With Android Support

Spearal is a new, open-source, serialization protocol that aims to overcome the limitations of JSON. It targets - as a first step - HTML and native mobile applications connected to a Java backend. Spearal 0.2.0 introduces Android support, in addition to...

Bloomfire Marketing10/28/14
493 views
0 replies

Dreamforce 2014, by CEO Trey Tramonte

Did you make it to Dreamforce? As a first timer myself, all I can say is WOW, it was everything that people had warned me of and more. A mega-event that is managed with uncommon precision and professionalism.

Adi Gaskell10/28/14
409 views
0 replies

Could Mobbr be facilitating fairer collaboration?

As regular readers of this blog will know, I’m a big fan of crowdsourcing as a method of attracting a wide and diverse range of talent towards a project. As the saying goes, “whoever you work for, the smartest people work for someone else”.