Sunday, July 19, 2009

Retrieving data from Sp List to Infopath using K2 SmartObjects.

Please consider the following steps.

1) Creation of ‘Employee’ smartobject using K2designer for VisualStudio.

fig1 :

1)2) Creting the ‘Employee ID’, ‘Employee Name’ properties for SmartObject.


3) Adding ‘GetList method’ to smartobject.

1) 4) Employee SmartObject deployment after addning the GetList method.


1) 5) Creating the Infopath form template to populate ‘Employee ID’ and ‘Employee Name’ details from ‘Employee SPList’ using the created ‘Employee SmartObject’.

6) 6)Integration of Employee SmartObject with ‘Employee Details Infopath form Template’.

v

6

1) 7) Adding the ‘Employee SmartObject’ GetList method as the Datasource to ‘Employee Details’ Infopath form Template.

1) 8) GetList method is added successfully to Infopath form template.

1) 9) Integration of ‘Employee SmartObject’ is completd Successfully.


1) 10) Providing the SmartObject data connection and a ‘Rule’ being taken to populate the data when form template opnes.


1) 11) Binding the datasource values to the Controls.


1) 12) But if I publish the form template to a sharepoint document library, the data population is done properly fig A:

fi

fig B:



Figc.



fig d:

For this example I’m accesissing the Sharepoint Site and Sharepoint List created in Server’s Image and I’m accessing the same to Client image.

On Client Image I have

1) K2Designer for VisualStudio (Used to create SmartObject).

2) MS Office Infopath 2007.

I’m able to run and get the data on the server image. But I’m unable to get the data in distributed environment. How to achieve this.

Sunday, July 12, 2009

Satyam Dotnet Interview Questions

Hi Friends , One of my Friend Attend the Dotnet Interview With Satyam

1. What is your qualification?

2. How many years of experience you have? In vb.net?

3. Tell about the recent project? What is your role in that module?

4. Which architecture implemented in this project?

5. Explain about the three tier architecture?

6. How the data will be passed to business layer?

7. What is the inheritance? *How to give quick fixes when there is a change involved in 100 web pages developed?

8. *What is the difference between abstract class and interface?

9. When will we use keyword shadows?

10. What are the access specifiers?

11. What is the scope of Shared?

12. *What is the difference between finalize and dispose?

13. What is the use of SCOPE_IDENTITY()? Difference between Ident_current() and SCOPE_IDENTITY()?

14. Write a query to fetch third maximum salary from emp table?

15. What is COALESCE()? Write a query to fetch data in a column values as a string separated by commas(x,y,z) ?

16. What is instead of trigger? How many instead of triggers can be defined on a table? If there are more than one trigger with same event (insert,update or delete exists) Which trigger will fire first?

17. How to use table output of one stored procedure in another stored procedure?

18. How to improve the performance in sql server?

19. How many types of indexes exists? What is the difference between clustered and non clustered index?

20. Up to which normalization, you have implemented in the tables used for the recent project?

21. What is demoralization?

22. What is the design part you have done in your module?

23. Is VB supports object oriented? *What is the difference between object based and object oriented?

24. What is the visual studio version currently using? And frame version?

25. Explain about dot net framework?

26. Explain about CLR?

27. What is managed code?

28. What is an assembly? *How many types of assemblies are there?

29. Explain the use of windows services?

30. What is polymorphism?

Saturday, July 4, 2009

Adding the Rows To Gridview From Footer



Fig1 :


using System;

using System.Collections.Generic;

using System.Linq;

using System.Web;

using System.Web.UI;

using System.Web.UI.WebControls;

using System.Data;

public partial class _Default : System.Web.UI.Page

{

protected void Page_Load(object sender, EventArgs e)

{

if (!Page.IsPostBack)

{

/* This is For Displaying Grid With Headers When Page is load */

string[] cols = new string[] { "hid", "SlNo", "Issues", "Remarks" };

DataTable dt_part = new DataTable();

for (int a = 0; a <>

{

DataColumn dc = new DataColumn(cols[a]);

dt_part.Columns.Add(dc);

}

Session["dt_part"] = dt_part;

dt_part = (DataTable)Session["dt_part"];

if (dt_part.Rows.Count == 0)

{

DataRow dr = dt_part.NewRow();

dr[0] = "";

dr[1] = "";

dr[2] = "";

dr[3] = "";

dt_part.Rows.Add(dr);

grdparticipents.DataSource = dt_part;

grdparticipents.DataBind();

}

else

{

grdparticipents.DataSource = dt_part;

grdparticipents.DataBind();

}

}

}

protected void grdparticipents_RowCommand(object sender, GridViewCommandEventArgs e)

{

if (e.CommandArgument.ToString() == "Add")

{

addrecord();

}

}

public void addrecord()

{

DataTable dtt = (DataTable)Session["dt_part"];

DataRow dr = dtt.NewRow();

dr["SlNo"] = ((TextBox)grdparticipents.FooterRow.FindControl("txtslno")).Text;

dr["Issues"] = ((TextBox)grdparticipents.FooterRow.FindControl("txtissues")).Text;

dr["Remarks"] = ((TextBox)grdparticipents.FooterRow.FindControl("Remarks1")).Text;

dtt.Rows.Add(dr);

if (dtt.Rows.Count >= 2)

{

if (dtt.Rows[0][0].ToString() == "" && dtt.Rows[0][1].ToString() == "" && dtt.Rows[0][2].ToString() == "" && dtt.Rows[0][3].ToString() == "")

{

dtt.Rows[0].Delete();

}

}

grdparticipents.DataSource = dtt;

grdparticipents.DataBind();

}

protected void grdparticipents_RowEditing(object sender, GridViewEditEventArgs e)

{

DataTable dtt = (DataTable)Session["dt_part"];

dtt.Rows[e.NewEditIndex].Delete();

if (dtt.Rows.Count == 0)

{

DataRow dr = dtt.NewRow();

dr[0] = "";

dr[1] = "";

dr[2] = "";

dr[3] = "";

dtt.Rows.Add(dr);

}

grdparticipents.DataSource = dtt;

grdparticipents.DataBind();

}

}