package javaapplication1;
/**
** @author sachika
*/
public class Main {
public static void main(String[] args) {
Main mainObj = new Main();
int no = mainObj.getNthUglyNo(11);
System.out.print(no);
try{
System.in.read();
}
catch(Exception s) {}
}
int maxDivide(int a, int b)
{
while (a%b == 0)
a = a/b;
return a;
}
boolean isUgly(int no)
{
no = maxDivide(no, 2);
no = maxDivide(no, 3);
no = maxDivide(no, 5);
return (no == 1)? true : false;
}
int getNthUglyNo(int n)
{
int i = 1;
int count = 1; /* ugly number count */
/*Check for all integers untill ugly count
becomes n*/
while (n > count)
{
i++;
if (isUgly(i))
count++;
}
return i;
}
}
In here I'm going to explain how to customize the SharePoint Item From to take parameters from Query String and set them as default values using SharePoint designer. Using this you can open a new Item From by providing parameters as query string. For an example you can customize one item Display form and taking query String Parameter from that and view New Item view for another list by providing default values using the Query String. Steps Open the SharePoint designer and go to list and libraries and open the list that you want. Click the New and create a New Insert View by providing the name of the view. Then created one will come to the list. then click and open the view. Then default New Item Screen will be loaded as follows. Then Delete the default list view and make that empty. You can delete the controls by selecting the area in the design view, If it fully cleared you can view the following message from the designer. Then go to SharePoint...
Comments
Certainly. And I have faced it. We can communicate on this theme. Here or in PM.