Showing posts with label to. Show all posts
Showing posts with label to. Show all posts
Friday, May 8, 2015
How To Rotate An Object in Inkscape Free Rotate Specific Degrees and 90 Degree Increments
Free Rotate An Object![]() ![]() Clicking on the Object again will change the Resizing Handles to Rotation and Skew Arrows. The Rotation Arrows are at the 4 Corners of the Object. Move the cursor over any one of them, hold the mouse button down, and turn the mouse in a Clockwise or Counter-clockwise direction to Free Rotate. Rotate Object To A Specified Degree | |
![]() ![]() Go to the Menu Bar and select Object > Transform. ![]() This will open the Transform Window which has 5 Tabs, namely Move, Scale, Rotate, Skew, and Matrix. Select the Rotate Tab. Where you see Angle, you will type in the Degrees you would like the Object to be Rotated. Keep in mind that to Rotate the Object Clockwise, you will have to enter a Negative Number (e.g. -30). To Rotate the Object Counter-clockwise you will have to enter a Positive Number (e.g. 30). Click on the Apply Button when finished. | |
Rotate Object in 90 Degree Increments![]() Go to the Menu Bar and select Object > Rotate 90 Deg CW. This will move your Object forward in a Clockwise Direction at 90 Degree Increments each time you use it. ![]() ![]() ![]() ![]() ![]() This will move your Object backward in a Counter-clockwise Direction at 90 Degree Increments each time you use it. ![]() ![]() ![]() ![]() |
Wednesday, February 18, 2015
Java program to display multiplication table of any number

class Table
{
public static void main(String...s)
{
int n,i;
n=Integer.parseInt(s[0]);
for(i=1;i<=10;++i)
System.out.println(n+" * "+i+" = "+(n*i));
}
}
C program to perform arithmetic operations using switch case

#include<stdio.h>
#include<conio.h>
#include<stdlib.h>
void main()
{
int ch;
float a,b,res;
clrscr();
printf("Enter two numbers:");
scanf("%f%f",&a,&b);
printf("
Menu
1.Addition
2.Subtraction
3.Multiplication
4.Division");
printf("
Enter your choice:");
scanf("%d",&ch);
switch(ch)
{
case 1: res=a+b;
break;
case 2: res=a-b;
break;
case 3: res=a*b;
break;
case 4: res=a/b;
break;
default: printf("Wrong choice!!
Press any key...");
getch();
exit(0);
}
printf("
Result=%f",res);
getch();
}
Labels:
arithmetic,
c,
case,
operations,
perform,
program,
switch,
to,
using
Tuesday, February 17, 2015
C program to print following square using character
#include<stdio.h>
#include<conio.h>
void main()
{
int i,j,n;
clrscr(); //to clear the screen
printf("Enter size of the square:");
scanf("%d",&n);
for(i=0;i<n;++i)
{
printf("
");
");
for(j=0;j<n;++j)
{
if(i==0||i==n-1||j==0||j==n-1)
printf("*");
else
printf(" ");
}
}
getch(); //to stop the screen
}
C Program to convert a lowercase alphabet to uppercase or vice versa
#include<iostream.h>
#include<conio.h>
void main()
{
clrscr();
char ch;
cout<<"Enter any Alphabet:";
cin>>ch;
if(ch>=a&&ch<=z)
{
cout<<"
You have entered a lowercase alphabet";
ch=ch-32;
cout<<"
The uppercase alphabet is "<<ch;
}
else
{
cout<<"
You have entered an Uppercase alphabet";
ch=ch+32;
cout<<"
The lowercase alphabet is "<<ch;
}
getch();
}
#include<conio.h>
void main()
{
clrscr();
char ch;
cout<<"Enter any Alphabet:";
cin>>ch;
if(ch>=a&&ch<=z)
{
cout<<"
You have entered a lowercase alphabet";
ch=ch-32;
cout<<"
The uppercase alphabet is "<<ch;
}
else
{
cout<<"
You have entered an Uppercase alphabet";
ch=ch+32;
cout<<"
The lowercase alphabet is "<<ch;
}
getch();
}
Monday, February 16, 2015
Turbo C for Windows XP How to Download and Install
Hello friends, after enjoying the festival of diwali I am back again to write something for you. Many visitors asked me that from where they can download turbo c++ for windows xp. So i thought that i should do something to help them. In this post i am giving you the link to download the compiler and step by step guide to install it.
- Click Here to Download Turbo C++ for Windows XP -
Also Read: Download Turbo C++ for Windows 8 for Free
Also Read: Download Borland C++ Compiler For Free
Also Read: Download Borland C++ Compiler For Free
How to Install Turbo C++ for Windows Xp
1. First of all download the compiler from the link given above.
2. Now extract the zip file and than open TC3SETUP.
3. After that click on Unzip. You can also change the path where you want to install it.
4. By default it is installed in C:TC.
5. You have done!! Please share and like it.
How To Hack Facebook Account With Keyloggers
![]() |
How To Hack Facebook With Keyloggers |
This tool is extremely easy to connect and use. All you have to do is give an email address and a password where the stolen information is to deliver. Can’t be easier than that.Just type in the email address and password and then click on the build button. A new “SERVER.EXE” file will be created and most of the work is already done. Now the big part comes. Just send this file to the victim. Rename it, change the icon and make it more presentable so that the victim opens it for sure.As soon as the victim opens the file, Server.exe will get all the passwords saved and facebook account credentials and will give them to you. To avoid detection, the facebook Hacker will also look for all the processes related to a security suite and kill them upon detection. The most important thing this software does is it kills all the security suite detecting it.
C Program to reverse all the strings stored in an array
#include<iostream.h>
#include<conio.h>
#include<string.h>
#include<stdio.h>
void main()
{
clrscr();
char a[3][50];
int i,j,k,len;
cout<<"Enter 3 strings:
";
for(i=0;i<3;i++)
{
gets(a[i]);
}
cout<<"
The list of orignal strings:
" ;
for(i=0;i<3;i++)
{
cout<<a[i]<<"
";
}
cout<<"
The list of changed string:
";
for(i=0;i<3;i++)
{
len=strlen(a[i]);
for(j=0,k=len-1;k>=0;j++,k--)
{
cout<<a[i][k];
}
cout<<"
";
}
getch();
}
Java Program to Find Union of two Arrays
For example we have two sorted arrays a1[]={2,3,5,11} and a2[]={4,7,9} then union of a1 and a2 will be {2,3,4,5,7,9,11}. A Java program for finding union of two arrays is given below.
Also Read: Java Program to Find Smallest and Largest Element in an Array
class demo
{
public static void main(String...s)
{
int i,j,n1,n2;
Scanner sc=new Scanner(System.in); //used to read from keyboard
System.out.print("Enter number of elements of first array:");
n1=sc.nextInt();
System.out.print("Enter number of elements of second array:");
n2=sc.nextInt();
int a1[]=new int[n1];
int a2[]=new int[n2];
System.out.print("
Enter elements of first array in ascending order:");
for(i=0;i<n1;++i)
a1[i]=sc.nextInt();
System.out.print("
Enter elements of second array in ascending order:");
for(i=0;i<n2;++i)
a2[i]=sc.nextInt();
i=j=0;
System.out.print("
Union of Arrays: ");
while(i<n1&&j<n2)
{
if(a1[i]<a2[j])
{
System.out.print(a1[i]+" ");
i++;
}
else
if(a2[j]<a1[i])
{
System.out.print(a2[j]+" ");
j++;
}
else
{
System.out.print(a1[i]+" ");
i++;
j++;
}
}
if(i<n1)
while(i<n1)
{
System.out.print(a1[i]+" ");
i++;
}
if(j<n2)
while(j<n2)
{
System.out.print(a2[j]+" ");
j++;
}
}
}

Also Read: Java Program to Find Smallest and Largest Element in an Array
Java Program to Find Union of two Arrays
import java.util.Scanner; //import Scanner class in our programclass demo
{
public static void main(String...s)
{
int i,j,n1,n2;
Scanner sc=new Scanner(System.in); //used to read from keyboard
System.out.print("Enter number of elements of first array:");
n1=sc.nextInt();
System.out.print("Enter number of elements of second array:");
n2=sc.nextInt();
int a1[]=new int[n1];
int a2[]=new int[n2];
System.out.print("
Enter elements of first array in ascending order:");
for(i=0;i<n1;++i)
a1[i]=sc.nextInt();
System.out.print("
Enter elements of second array in ascending order:");
for(i=0;i<n2;++i)
a2[i]=sc.nextInt();
i=j=0;
System.out.print("
Union of Arrays: ");
while(i<n1&&j<n2)
{
if(a1[i]<a2[j])
{
System.out.print(a1[i]+" ");
i++;
}
else
if(a2[j]<a1[i])
{
System.out.print(a2[j]+" ");
j++;
}
else
{
System.out.print(a1[i]+" ");
i++;
j++;
}
}
if(i<n1)
while(i<n1)
{
System.out.print(a1[i]+" ");
i++;
}
if(j<n2)
while(j<n2)
{
System.out.print(a2[j]+" ");
j++;
}
}
}

Sunday, February 15, 2015
16 Ways To Hack Facebook Account
![]() |
16 Ways To Hack Facebook Account |
1:Brute Force Attacks
2:Dictionary Attacks
3:Cracking Facebook Accounts
4:Hack A Facebook Account By Exploiting Facebooks Trusted Friend Feature
5:Keylogging
6:Hijacking Facebook Fan Pages
7:Hack Facebook Account Status - Facebook Status Vulnerability
8:Facebook phishing
9:Stealers
10:Session Hijacking
11:Sidejacking With Firesheep
12:DNS Spoofing
13:USB Hacking
14:Man In the Middle Attacks
15:Botnets
16:Movable Mobile Hacking
C program to swap two numbers using macros

#include<iostream.h>
#include<conio.h>
#define SWAP(a,b) {int temp; temp=a; a=b; b=temp;}
void main()
{
clrscr();
int x,y;
cout<<"Enter two numbers:";
cin>>x>>y;
cout<<"x="<<x<<" y="<<y;
SWAP(x,y);
cout<<"
x="<<x<<" y="<<y;
getch();
}
Saturday, February 14, 2015
C Program to explain Binary search in Array
#include<conio.h>
#include<iostream.h>
void main()
{
int search(int [],int,int);
clrscr();
int n,i,a[100],e=-3,res;
cout<<"How Many Elements:";
cin>>n;
cout<<"
Enter Elements of Array in Accending order
";
for(i=0;i<n;++i)
{
cin>>a[i];
}
cout<<"
Enter element to search:";
cin>>e;
res=search(a,n,e);
if(res!=0)
cout<<"
Element is Founded at "<<res+1<<"st position";
else
cout<<"
Element is not found....!!!";
getch();
}
int search(int a[],int n,int e)
{
int f,l,m;
f=0;
l=n-1;
while(f<=l)
{
m=(f+l)/2;
if(e==a[m])
return(m);
else
if(e>a[m])
f=m+1;
else
l=m-1;
}
return 0;
}
C program to find factorial of any number using recursion

#include<stdio.h>
#include<conio.h>
void main()
{
int fac,n;
int factorial(int);
clrscr();
printf("Enter any number:");
scanf("%d",&n);
fac=factorial(n);
printf("Factorial=%d",fac);
getch();
}
int factorial(int x)
{
int f;
if(x==1||x==0)
return 1;
else
f=x*factorial(x-1);
return f;
}
Friday, February 13, 2015
HowTo Fix Pango WARNING failed to create cairo scaled font
Problem:
I encountered this problem on newly installed and updated Fedora 20

Pango-WARNING **: failed to create cairo scaled font, expect ugly output. the offending font is Arial Bold 19.53125 at /usr/lib64/perl5/vendor_perl/dpm/canvas_module.pm line 253.
Pango-WARNING **: font_face status is: out of memory at /usr/lib64/perl5/vendor_perl/dpm/canvas_module.pm line 253.
Pango-WARNING **: scaled_font status is: out of memory at /usr/lib64/perl5/vendor_perl/dpm/canvas_module.pm line 253.
Pango-WARNING **: shaping failure, expect ugly output. shape-engine=BasicEngineFc, font=Arial Bold 19.53125, text= 3R at /usr/lib64/perl5/vendor_perl/dpm/canvas_module.pm line 253.
Solution:
1. open terminal
2. su -
3. chmod -Rf 777 /usr/share/fonts/*
4. Tada! Everything should be fixed now!
Read more »
I encountered this problem on newly installed and updated Fedora 20

Pango-WARNING **: font_face status is: out of memory at /usr/lib64/perl5/vendor_perl/dpm/canvas_module.pm line 253.
Pango-WARNING **: scaled_font status is: out of memory at /usr/lib64/perl5/vendor_perl/dpm/canvas_module.pm line 253.
Pango-WARNING **: shaping failure, expect ugly output. shape-engine=BasicEngineFc, font=Arial Bold 19.53125, text= 3R at /usr/lib64/perl5/vendor_perl/dpm/canvas_module.pm line 253.
Solution:
1. open terminal
2. su -
3. chmod -Rf 777 /usr/share/fonts/*
4. Tada! Everything should be fixed now!
C program to print the following pattern

#include<iostream.h>
#include<conio.h>
void main()
{
clrscr(); //to clear the screen
int i,j,k,n;
cout<<"How many lines?";
cin>>n;
n*=2;
for(i=0;i<n;i+=2)
{
cout<<"
";
for(j=n;j>i;j-=2)
cout<<" ";
for(k=0;k<=i;++k)
cout<<"*";
}
getch(); //to stop the screen
}
Thursday, February 12, 2015
C program to find greatest number among three numbers

#include<stdio.h>
#include<conio.h>
void main()
{
int x,y,z,max;
clrscr();
printf("Enter The Three Numbers:");
scanf("%d%d%d",&x,&y,&z);
max=x;
if(y>max&&y>z)
max=y;
else
if(z>max)
max=z;
printf("
The Greatest Number among %d %d %d is %d",x,y,z,max);
getch();
}
C program to add two numbers using structure

#include<stdio.h>
#include<conio.h>
struct sum
{
int a;
int b;
};
void main()
{
int sum1;
struct sum s;
clrscr();
printf("Enter two numbers:");
scanf("%d%d",&s.a,&s.b);
sum1=s.a+s.b;
printf("
Sum=%d",sum1);
getch();
}
C program to swap two numbers using pointers

#include<iostream.h>
#include<conio.h>
void main()
{
clrscr();
int *a,*b,*temp;
cout<<"Enter value of a and b:";
cin>>*a>>*b;
temp=a;
a=b;
b=temp;
cout<<"
After swaping
a="<<*a<<"
b="<<*b;
getch();
}
C program to find sum of series 1 1 2 2 1 3 3 1 n n

#include<iostream.h>
#include<conio.h>
#include<math.h>
void main()
{
clrscr();
double sum=0,a;
int n,i;
cout<<"1+1/2^2+1/3^3+.....+1/n^n";
cout<<"
Enter value of n:";
cin>>n;
for(i=1;i<=n;++i)
{
a=1/pow(i,i);
sum+=a;
}
cout<<"Sum="<<sum;
getch();
}
Drill down from one dashboard to another dashboard in Pentaho CDE Simple Example Not included any parameters
Hi Guys,
This post will teach you how you can drill down from one dashboard to another dashboard in pentaho CDE. This workout has done by one of my colleagues who is a fast learner.
You need to focus on 2 things in this post:
1) Connecting to JDBC datasource
2) Drill down from one dashboard to another dashboard.
NOTE :
Ill update you in next post about drill down from one dashboard to another dashboard using custom parameters concept.(Next work out).
Versions & Tools used for this post:
Pentaho C-Tools(CDE,CDA,CDF) 13.09 stable.
PostgreSQL DB - (foodmart database - which is one of jasperserver default databases)
Pentaho BA server 4.8 stable.
SOURCE CODE OF THE EXAMPLE
Download the example using below link
https://drive.google.com/file/d/0BymV_QP4TGBEZ0p1cnpydDJGeDQ/edit?usp=sharing
Deployment procedure:
1) Down load the .rar file from the link(File-Download in the google drive)
2) Unzip it and place it in "pentaho-solutions" folder.
3) Refresh or clear the cache of the pentaho browser(find upper left - Browser)
4) If you are unable to find the folder name , you need to create an index.xml file (Eg: you can find it inside any folder. copy and paste it inside your working folder and change the name of it).
5) No need to restart the pentaho server.
NOTE: Edit data base connections as per your requirement also you may need to change the query if you use any other database than foodmart
Dashboard 1:
1) Layout section
* Design your lay out for dashboard1
2) Components section
* You will be placing 1 bar chart where you will click on bars for drilling down to another dashboard.
We will come back to this section again after designing Dashboard 1 and Dashboard 2
3) Data Sources section
* Click on Data source Icon on right top conrner.
* From the left .. click on SQL queries -> Click on sql over sqljdbc
* Give the name and all the properties as shown in below image.

NOTE:
PostgreSQL server default details :
Driver: org.postgresql.Driver
UserName : postgres
Password : postgres
URL: jdbc:postgresql://localhost:6062/foodmart where 6062 is the port number which I used for postgres and foodmart is the database.
Note that default port number for postgresSQL is 5432 .
* Write a query which will suits for bars in the chart
* For eg:
SELECT
c.country,
c.state_province ,
c.city,
SUM(sf.store_sales)
FROM
customer c,
sales_fact_1997 sf
WHERE c.customer_id=sf.customer_id
GROUP BY
c.country,
c.state_province,
c.city
ORDER BY
c.country,c.state_province,c.city
* See the preview of the dashboard
* Out put will looks like below.

Dashboard 2 :
* Repeat the same steps as followed in Dashboard 1
* Take any component to display on the second dashboard.
* I have taken table component in this example and the output will looks like below mentioned image.
*

We have done with 2 dashboards individually.
Now, Its the time for us to some trick on Dashboard 1 so that when we click on Dashboard 1 , it will have to take you to Dashboard2
Steps:
1) Lets go back to Dashboard 1
2) Go to the Chart component and in the properties give clickable as True
3) In the clickAction you need to give the URL of second dashboard in java script.
Eg:
function q(s,c,v)
{
window.location = http://localhost:8085/pentaho/content/pentaho-cdf-dd/Render?solution=CDE-+Exploring&path=%2FDevelopement%2FDashboard+Drill+down&file=drill_down_to_table.wcdf;
}
Thats it you have done with drill down. Save the dashboard 1 and see the preview and then click on any bar appearing , you will navigate to the 2nd dashboard.
NOTE :
This post is only giving the idea of how to drill down from one dash board to another dashboard.
This post doesnt work with any parameters. The use custom parameter with drill down from 1 dashboard to another dashboard will come in next post from my end.
URL generating problem / Path problem for Second Dashboard
How to generate the URL for 2nd dashboard ( not only for this but also works for every dashboard).?
* Right click on 2nd Dashboard and click on "Open In New Tab" the with the URL the 2nd dashboard will open in fresh tab.
* Copy that URL and paste in drill down function.
* For eg : Just reference : Find the images below

References :
1) http://forums.pentaho.com/showthread.php?152634-Drill-down-from-bar-chart-to-another-dashboard
2) http://forums.pentaho.com/showthread.php?82999-Drill-Down-in-DashBoards
Sadakar
("Learning never exhausts the mind")
This post will teach you how you can drill down from one dashboard to another dashboard in pentaho CDE. This workout has done by one of my colleagues who is a fast learner.
You need to focus on 2 things in this post:
1) Connecting to JDBC datasource
2) Drill down from one dashboard to another dashboard.
NOTE :
Ill update you in next post about drill down from one dashboard to another dashboard using custom parameters concept.(Next work out).
Versions & Tools used for this post:
Pentaho C-Tools(CDE,CDA,CDF) 13.09 stable.
PostgreSQL DB - (foodmart database - which is one of jasperserver default databases)
Pentaho BA server 4.8 stable.
SOURCE CODE OF THE EXAMPLE
Download the example using below link
https://drive.google.com/file/d/0BymV_QP4TGBEZ0p1cnpydDJGeDQ/edit?usp=sharing
Deployment procedure:
1) Down load the .rar file from the link(File-Download in the google drive)
2) Unzip it and place it in "pentaho-solutions" folder.
3) Refresh or clear the cache of the pentaho browser(find upper left - Browser)
4) If you are unable to find the folder name , you need to create an index.xml file (Eg: you can find it inside any folder. copy and paste it inside your working folder and change the name of it).
5) No need to restart the pentaho server.
NOTE: Edit data base connections as per your requirement also you may need to change the query if you use any other database than foodmart
Dashboard 1:
1) Layout section
* Design your lay out for dashboard1
2) Components section
* You will be placing 1 bar chart where you will click on bars for drilling down to another dashboard.
We will come back to this section again after designing Dashboard 1 and Dashboard 2
3) Data Sources section
* Click on Data source Icon on right top conrner.
* From the left .. click on SQL queries -> Click on sql over sqljdbc
* Give the name and all the properties as shown in below image.

NOTE:
PostgreSQL server default details :
Driver: org.postgresql.Driver
UserName : postgres
Password : postgres
URL: jdbc:postgresql://localhost:6062/foodmart where 6062 is the port number which I used for postgres and foodmart is the database.
Note that default port number for postgresSQL is 5432 .
* Write a query which will suits for bars in the chart
* For eg:
SELECT
c.country,
c.state_province ,
c.city,
SUM(sf.store_sales)
FROM
customer c,
sales_fact_1997 sf
WHERE c.customer_id=sf.customer_id
GROUP BY
c.country,
c.state_province,
c.city
ORDER BY
c.country,c.state_province,c.city
* See the preview of the dashboard
* Out put will looks like below.

Dashboard 2 :
* Repeat the same steps as followed in Dashboard 1
* Take any component to display on the second dashboard.
* I have taken table component in this example and the output will looks like below mentioned image.
*

We have done with 2 dashboards individually.
Now, Its the time for us to some trick on Dashboard 1 so that when we click on Dashboard 1 , it will have to take you to Dashboard2
Steps:
1) Lets go back to Dashboard 1
2) Go to the Chart component and in the properties give clickable as True
3) In the clickAction you need to give the URL of second dashboard in java script.
Eg:
function q(s,c,v)
{
window.location = http://localhost:8085/pentaho/content/pentaho-cdf-dd/Render?solution=CDE-+Exploring&path=%2FDevelopement%2FDashboard+Drill+down&file=drill_down_to_table.wcdf;
}
Thats it you have done with drill down. Save the dashboard 1 and see the preview and then click on any bar appearing , you will navigate to the 2nd dashboard.
NOTE :
This post is only giving the idea of how to drill down from one dash board to another dashboard.
This post doesnt work with any parameters. The use custom parameter with drill down from 1 dashboard to another dashboard will come in next post from my end.
URL generating problem / Path problem for Second Dashboard
How to generate the URL for 2nd dashboard ( not only for this but also works for every dashboard).?
* Right click on 2nd Dashboard and click on "Open In New Tab" the with the URL the 2nd dashboard will open in fresh tab.
* Copy that URL and paste in drill down function.
* For eg : Just reference : Find the images below


References :
1) http://forums.pentaho.com/showthread.php?152634-Drill-down-from-bar-chart-to-another-dashboard
2) http://forums.pentaho.com/showthread.php?82999-Drill-Down-in-DashBoards
Sadakar
("Learning never exhausts the mind")
Subscribe to:
Posts (Atom)