Thursday, October 3, 2013

Preparing Physical Self for weight loss.

Starting a Weight Loss program is as easy as tempting into a bar of chocolate and indulging into 1 at midnight.The worst part of it is about realizing its direct impact on body is after that craving is done.

Most of us start our weight-loss program with a craving of looking good and slimmer. How do we know that a particular type of slimming technique suits an individual.Lets think for a while.

Craving and weight-loss, both the decisions are being taken by our brain. Our body obeys it. Means our Physical self is a slave of our intention, imagination, desire, satisfaction. The very existence of human is in his/her physical body. Its pathetic that we, so-called nexgen normal humans hardly listen to our body, carried away with the fancy hoarding of food outlets/packets and satisfy our mental status by consuming them.

For those who are willing to start off their weight-loss programs which ever they prefer - yoga, exercise, green tea, organic,.... please please please ... talk to your physical self. Its like taming a naughty child inside you. This naughty child is your desire to satisfy your cravings. This child sometimes needs to be cuddled, sometimes to be rude. sometimes food that is loved, sometimes food that is good for health. This balance makes the child listen to you and start loving you.

Prepare child for preschool = prepare body to start weight-loss program
do you think the child needs a preschool = body needs an external help.
if so, which preschool is good=available weight-loss programs
extra pampering given to child to get prepared for preschool= new material to start the weight-loss
when ever child gets bored give him new stuff=change the kind of cuisine
when child gets even bored= be a little rude on him

This kind of thinking would try to bridge the mental and physical self's together and makes wonders in maintaining the same BMI over a very long time.

Starting of my weight loss program 80 to 60

I put on a lot of weight after my second delivery and with time's disgrace I suffered with chicken guinea which I should say that no one should suffer...

I was unable to hold my baby for months.

I decided to start weight loss program with my 5th wedding anniversary was nearing-by. I read couple of magazines, watched some TV shows out of which I found Mantena Satyanarayana Naturopathist. His way of weight loss techniques seemed very difficult for me. But there are some basics which every born-as-human to be followed. They are the importance of intake of water, food at right time.

http://www.youtube.com/watch?v=UdqrK4rvqzI&list=PLD81A81E447BF3200

Its just the basics I started with his tutorials but the rest I should say is completely on the way my body echoed to me.

Friday, June 18, 2010

back in blogging

with a lot of gap...

I am now jump starting my blogging again..

I am no more the same girl ... being a mother for two..mauriya and saakya.. I am now enjoying another phase of womenhood.

Thanks for all my family members for their support yhrough out this period.

Monday, December 31, 2007

Deploying ASP.NET Web application using web deployment project

Its known from many posts in most of the blogs that use of web deployment project in a solution is a better option than opting for XCOPY or copy project.

This post explains my experience using the web deployment project for one of my web application.

Creating a Web Setup Project: Using Visual Studio .NET InstallerWe will start by adding a new Web Setup Project to our deployusingInstaller ASP.NET Web application solution by selecting File->Add Project-> New Project from the menu. In the New Project dialog box, select Setup and Deployment Projects from the Project Types pane and then select Web Setup Project in the Templates pane.


After creating the project, you then need to add the output of the primary assembly and the content files of the ASP.NET Web application to the setup project. To do this, right click on the deployusingInstaller project in the solution explorer and select Add->Project Output from the context menu. In the Add Project Output Group dialog box, select deployusingInstaller from the Project drop down list and select Primary Output from the list.


After adding the project output, you then need to add the related Content Files (such as .aspx files, Images, and so on) to the project. To do this, again bring up the Add Project Output dialog box and then select Content Files from the list this time.

Configuring Properties through the Properties:
There are a number of properties that you can set through the properties window of the Web Setup project. These properties determine the runtime display and behavior of the Windows installer file. To accomplish this, right click on the deployusingInstaller project from the solution explorer and select Properties from the context menu to bring up its properties window.

Installing the ASP.NET Web Application:
Once you have created the Windows installer file (.msi file), then installing the ASP.NET application in the target servers is very straightforward. All you need to do is to double-click on the .msi file from the Windows explorer. This will initiate the setup wizard, which will walk you through the installation steps.


Clicking on Next, results in the following dialog box, where you can specify the virtual directory that will be used to host this Web application. This is one of the handy features wherein the creation of virtual directory is completely automated obviating the need for manual intervention.

In dialog box, you can also click on the Disk Cost... command button to get an idea of the space required for installing this Web application. Clicking on Next in the above dialog box results in the following dialog box where you are asked to confirm the installation.

When you click on Next in the dialog box, the installation will begin and the application will be installed. The application is successfully installed.

After installing the application, you can see the installed ASP.NET application through the Add/Remove Programs option (that can be accessed through Start->Settings->Control Panel) in your computer. From here, you can run the setup program to uninstall the application any time you want to.

Tuesday, June 26, 2007

code to dynamically generate rows on click on ButtonField in gridview

ofcourse there are many posts available on to generate rows dynamically on button click..

I would like to share the code of scenario where in the clickevent (commandname) of buttonfield in gridview would dynamically generate the rows ....

The buttonfield is binded to gridview whose commandname is accessed in the RowBound event of gridview as shown below...

protected void gvStores_RowCommand(object sender, GridViewCommandEventArgs e)
{
if (e.CommandName == "myCommandAdd")
{
int index = Convert.ToInt32(e.CommandArgument);
GridViewRow selectedRow = gvStores.Rows[index];
TableCell store = selectedRow.Cells[6];
al.Add(Convert.ToInt16(store.Text));
CreateTextBoxControls1(al);
}

method CreateTextBoxControls1() takes input of various click events of gridview which are stored in a static arraylist.


private void CreateTextBoxControls1(ArrayList al)
{
int rowCount = al.Count;

Table tbl = new Table();
if (tbl.GetType().ToString().Equals("System.Web.UI.WebControls.Table") && Placeholder1.FindControl("tbl") == null)
{
tbl.ID = "tbl";
}
tbl.EnableViewState = true;
for (int rowIndex = 0; rowIndex < rowCount; rowIndex++)
{
TableRow tr = new TableRow();
TableCell tc = new TableCell();

Label _lblBookStore = new Label();
Button _btnDelete = new Button();

_lblBookStore.ID = "lblBookStore" + (rowIndex + 1).ToString();
_lblBookStore.Text =""+al[rowIndex];
tc.Controls.Add(_lblBookStore);

_btnDelete.ID = "btnDelete" + (rowIndex + 1).ToString();
_btnDelete.Text = "MyBookstore";
_btnDelete.Click += new EventHandler(_btnDelete_Click);
tc.Controls.Add(_btnDelete);

tr.Cells.Add(tc);
tblHelp.Rows.Add(tr);
}
Placeholder1.Controls.Add(tbl);
}

thus the place holder gets various rows added to the page dynamically and can associate an AJAX effect by binding the place holder and gridview inside an update panel.

code to generate a file based on the number of users logged in specific time

I happened to write a console application to generate a file based on the number of users logged in specific time. I hope this might be useful since its interesting to work with console application after a long time.

.. I hope this makes sense for all whose looking for a starting point for writing such applications..


static void Main(string[] args)
{
String[] commandLineArgs = System.Environment.GetCommandLineArgs();
int duration = System.Convert.ToInt32(commandLineArgs[1]);
int delay = System.Convert.ToInt32(commandLineArgs[2]);
String str = commandLineArgs[3];
SqlConnection conn = new SqlConnection();
conn.ConnectionString = "server=myserver;uid=sa;password=sa;Initial Catalog=AdventureWorks;";
conn.Open();
FileStream fs = File.Create("c:\\ " + str + ".log");
StreamWriter sw = new StreamWriter(fs);
while (duration > 0)
{
SqlDataAdapter da = new SqlDataAdapter("SELECT * FROM [AdventureWorks].[dbo].[myTestTable]", conn);
DataSet ds = new DataSet();
StringBuilder stb = new StringBuilder();
da.Fill(ds);
if (ds.Tables.Count > 0)
{
if (ds.Tables[0].Rows.Count > 0)
{
for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
{
if (ds.Tables[0].Columns.Count == 2 && i == 0)
{
sw.WriteLine(ds.Tables[0].Columns[0].ColumnName + " " + ds.Tables[0].Columns[1].ColumnName);
sw.WriteLine("=====================================");
}
string info = ds.Tables[0].Rows[i][0].ToString() + " " + ds.Tables[0].Rows[i][1].ToString();
sw.WriteLine(info);
}
sw.WriteLine();
}
}
Thread.Sleep(delay * 1000);
duration = duration - 1;
}
sw.Close();
fs.Close();
}
}

To run the application..
goto commandprompt of visual studio and change the directory to debug of the current application and type

myapplication.exe 10 10 mylog

this refers to run the exe of the application with arguments duration of 1min and delay of 10 sec and name of the file to log the needed information.

Wednesday, May 16, 2007

CRM Customization

This post is about a short term work done on MSCRM. Customizing the reports for CRM.

let me walkthrough various terms I am going to discuss in this post

MSCRM:
set up CRM server with organization name as the name of the server.
it can be accessed by http://organizationname/loader.aspx
The referances to various view can be obtained by chceking the mappings and attributes in CRM->Settings
The drilldown reports to be placed under Hidden reports section of CRM. To acieve this, the selection for the type of reports to be empty.Otherwise the respective classification under which the report appears can be placed like Marketing, Sales, Services reports.
Also the respectives views include needs to be referred during importing the report onto CRM. Example:Account, Campaign Response, Campaigns, service appointment, activities, Meter, Oppurtunities etc.
MSCRM customization:
import customizatons pertaining to the organization. this can be done by settings->import customization->import the referred file. The new changes made is refelected by new_() in database tables and respective fields in tables.
To design the default filter, one need to specify its Aliasing Filter for a particular View (Example:FilteredAccount) while writing the query for the report.
SSRS Reports:
The reports can be activated for drill down by selecting the properties->data tab->Edit (in values section) ->Action->Jump to report.
Reports exported to CRM:
The reports were produced using SSRS. The parameters in the "where" condition of query in SSRS will themself become select clauses at runtime.
Global Variables for CRM:
CRM global level variables are to be declared using "CRM_". Typical examples include
CRM_URL == for drilldown.
CRM_FilterText == for getting the filtered values on to the reports.
CRM_SortField == for sorting
CRM_SortDirection == sort direction (Ascending/Descending)
Defining the sort direction for tabular reports:
The following is code for getting the arrow in the table header and implementing the same for sorting. Report -> Report Properties -> Code

Function GetArrow(SortField As String, SortColumn As String, SortDirection As String)As String
If
SortField = SortColumn
then if
SortDirection ="Ascending"
then
Return "D"
Else
Return "Ñ"
End If
Else
Return ""
End If
End Function
The following is code for table details for get refreshed while sorting
=IIF(IsNothing(Parameters!CRM_URL.Value),Nothing,Parameters!CRM_URL.Value & "?ID={"&Fields!myTabledetailName.Value.ToString()&"}&OTC=4400")