I think this is a perfect case for the modulus operator.
DataContext db = new DataContext();
for(int month = 1; month <= 12; month++)
{
DataEntry de = new DataEntry();
de.ID = 1;
de.venuelID = 21;
de.VOM = (month % 1) == 0;
db.DataTable.InsertOnSubmit(de);
DataEntry de = new DataEntry();
de.ID = 10;
de.venuelID = 92;
de.VOM = (month % 2) == 0;
db.DataTable.InsertOnSubmit(de);
DataEntry de = new DataEntry();
de.ID = 21;
de.venuelID = 102;
de.VOM = (month % 3) == 0;
db.DataTable.InsertOnSubmit(de);
}
db.SubmitChanges();
Is this what you want or have i missunderstod?
Andreas Johansson
IT Professional at Office IT Partner i Norrbotten Sweden
What we don't know. We learn.
What you don't know. We teach
You can connect to a pop3 server using a TCP connection. Once the connection established, there are a set of commands to communicate with pop3 server. There is an RFC[^] for these commands.
If you create a proxy to your web service you can dynamically switch between different urls. The proxy class could look something like this:
class WebServiceProxy : YourWebservices.orderService
{
public WebServiceProxy(string p_url)
{
this.Url = p_url;
}
}
Then the call looks like:
WebServiceProxy ws = new WebServiceProxy("yoururl");
ws.yourMethod();
Hope that helps. Ben
Have a look at this[^] article. It traps the paste event (overrides WndProc and handles WM_PASTE), which is what you wanted. Regards Senthil _____________________________ My Blog | My Articles | WinMacro
Hi there, If you want to customize the default context menu of the browser, you can provide some client side script for the oncontextmenu[^] event to do that. In addition, you can also google for a third party component available out there.
Dear Mike, Thanx for the reply.any way what i want is to create common web page to display all the nesessary data request from other pages.not to create a common function and call it on other pages. i just want to create common data view page for other child pages.so when the user select the filling criteria from child page the top.aspx page have to display the correct data. e.g : say user going to modify the project details.but before that he wants to view entered project details.when he click the button which is in bottom.aspx my common data fill page that is top.aspx should fill out all entered project details. at the movement i use querystring for this.but i think it's not practical for this.. as a another solution i can do this by creating user control also.but i just want to do that another way. Thanx
Can you run your application in debug mode and try to see the values of the CurrentPageIndex and PageCount properties before the error happens? I doubt that those values are not inline with your datasource (the arraylist instance). If you just use a single web page for both listing all items and adding a new item, then you'll have to rebind the datasource to the datagrid so that it can reflect the updated datasource.