ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
tip   SiteMap shows list of All Categories in this site.
Google
 
Categories >> Software >> Microsoft-Related >> VB.NET
 
 


 

Back to Questions Page
 
Question
how to connect crystal report with vb.net ?
Rank Answer Posted By  
 Question Submitted By :: Guest
This Interview Question Asked @   Patni
I also faced this Question!!   © ALL Interview .com
Answer
Click on Project menu
-->then Click Add New Item
-->Choose Crystal Report
-->Give the name of the report that you want to give
-->Click on Add Report
 
0
Sonia
 
 
Answer
Follow These Steps:
Click on Project menu
-->then Click Add New Item
-->Choose Crystal Report
-->Give the name of the report that you want to give
-->Click on Add Report
and also
-->Click Add New Dataset(.XSD File)
-->Right Click on That File Add Table Adapter
-->Make Connection and Write The Query and Follow The Step 
as Come In Wizard
-->The In Blank Report Go Field Explore
-->DataBase Fields and Chose ADO.NET Dataset it The Table 
you have Create in Dataset 
-->Now Drag and Drop it in You Reports
 
0
Dinesh Sharma
 
 
Answer
Public Sub ReportView(ByVal RepoPath As String, Optional 
ByVal param As String = "")
        Dim ConInfo As New 
CrystalDecisions.Shared.TableLogOnInfo
        Dim objReport As New 
CrystalDecisions.CrystalReports.Engine.ReportDocument
        Dim strParamenters As String = param
        Dim strParValPair() As String
        Dim index As Integer
        Dim strVal() As String
        Dim Para As String
        Dim Val As String

        objReport.Load(RepoPath)
        If Trim(param) <> "" Then
            strParValPair = strParamenters.Split("&")
            For index = 0 To UBound(strParValPair)
                If InStr(strParValPair(index), "=") > 0 Then
                    strVal = strParValPair(index).Split("=")
                    Para = strVal(0)
                    Val = strVal(1)
                    objReport.SetParameterValue(Para, Val)
                End If
            Next
        End If
        LoginCR(objReport)

        For Each Table As 
CrystalDecisions.CrystalReports.Engine.Table In 
objReport.Database.Tables
            ConInfo = Table.LogOnInfo
            ConInfo.ConnectionInfo.UserID = "UserName"
            ConInfo.ConnectionInfo.Password = "Password"
            ConInfo.ConnectionInfo.ServerName = "Your 
Server Name"
            ConInfo.ConnectionInfo.DatabaseName 
= "Attendance"
            Table.ApplyLogOnInfo(ConInfo)
        Next
        
FrmCrystalRptViewer.CrystalReportViewer1.DisplayGroupTree = 
False
        
FrmCrystalRptViewer.CrystalReportViewer1.ReportSource = 
Nothing
        
FrmCrystalRptViewer.CrystalReportViewer1.ReportSource = 
objReport
        FrmCrystalRptViewer.Show()
        
FrmCrystalRptViewer.CrystalReportViewer1.DisplayGroupTree = 
False
        FrmCrystalRptViewer.CrystalReportViewer1.Show()
    End Sub
    Private Sub LoginCR(ByRef CRep As 
CrystalDecisions.CrystalReports.Engine.ReportDocument)
        Dim LogonInfo As 
CrystalDecisions.Shared.TableLogOnInfo
        For Each Table As 
CrystalDecisions.CrystalReports.Engine.Table In 
CRep.Database.Tables
            ConInfo = Table.LogOnInfo
            ConInfo.ConnectionInfo.UserID = "UserName"
            ConInfo.ConnectionInfo.Password = "Password"
            ConInfo.ConnectionInfo.ServerName = "Your 
Server Name"
            ConInfo.ConnectionInfo.DatabaseName 
= "Attendance"
            Table.ApplyLogOnInfo(LogonInfo)
        Next
    End Sub
 
0
Himanshu
 
 
 
Answer
Take crystal report from toolbox .Take New form (I named it 
frmRpt)Then take crystal report Viewer from tool box and 
place it on new form(frmRpt) I named crystal report Viewer 
as crptVW 
double click on newform(frmRpt) and place this code---

Public Class frmRpt
    Public strRptName As Object
    Public strRptFilter As String
    Private Sub frmRpt_Load(ByVal sender As System.Object, 
ByVal e As System.EventArgs) Handles MyBase.Load
        If strRptFilter <> "" Then
            crptVW.SelectionFormula = strRptFilter
        End If
        crptVW.ReportSource = strRptName
        crptVW.Show()
    End Sub
End Class


now if u want to call it on button_click then paste this 
code on that button_click event ------

Dim objRpt As New frmRpt
        objRpt.strRptName = New crList
        ' objRpt.strRptFilter = "{ConsultantMaster.ConId}=" 
& cboConIDX.SelectedValue 'if want to filter
        objRpt.Show()

'now u can open as many crystal report just paste code 
above on button_click()
 
0
Kafeel Ahmad
 
 
Answer
1)how to connect crystal report with vb.net ?
2)how to pass the parameter?
 
0
Vinod Kondhalkar
 
 
Answer
by connection strings
 
0
Guest
 
 
Question
concept of object oriented programming
Rank Answer Posted By  
 Question Submitted By :: Shrikant
This Interview Question Asked @   Patni
I also faced this Question!!   © ALL Interview .com
Answer
Classes,obects,methods,Events

Data Abstraction,Data Encapsulation,Polymorphism,Inheritance
 
3
Swapna Reddy
 
 
Answer
what are the oops concept?
 
0
Sharanbhabu
 
 
Answer
There are 8 main thnigs, they are:
Class,object,method,inheritance,Polimorphism,Data binding,
Encapsulation,Data Abstraction.
 
1
Nithya.v
 
 
Answer
There are 9 main thnigs, they are:
Class,object,method,inheritance,Polimorphism,Data binding,
Encapsulation,Data Abstraction,message passing.
 
2
Arputharaj
 
 
Answer
Its a technique where we see the real world in terms of 
objects
 
0
Sandeep Pokala
 
 
Question
how to connect crystal report with vb.net ?
Rank Answer Posted By  
 Question Submitted By :: Guest
This Interview Question Asked @   Patni
I also faced this Question!!   © ALL Interview .com
Answer
Click on Project menu
then Click Add New Item
Choose Crystal Report
Give the name of the report that you want to give
Click on Add Report
 
2
Ranjith
 
 
Answer
Take crystal report from toolbox .Take New form (I named it 
frmRpt)Then take crystal report Viewer from tool box and 
place it on new form(frmRpt) I named crystal report Viewer 
as crptVW 
double click on newform(frmRpt) and place this code---

Public Class frmRpt
    Public strRptName As Object
    Public strRptFilter As String
    Private Sub frmRpt_Load(ByVal sender As System.Object, 
ByVal e As System.EventArgs) Handles MyBase.Load
        If strRptFilter <> "" Then
            crptVW.SelectionFormula = strRptFilter
        End If
        crptVW.ReportSource = strRptName
        crptVW.Show()
    End Sub
End Class


now if u want to call it on button_click then paste this 
code on that button_click event ------

Dim objRpt As New frmRpt
        objRpt.strRptName = New crList
        ' objRpt.strRptFilter = "{ConsultantMaster.ConId}=" 
& cboConIDX.SelectedValue 'if want to filter
        objRpt.Show()

'now u can open as many crystal report just paste code 
above on button_click()
 
0
Kafeel Ahmad
 
 
Question
when we will use console ?
Rank Answer Posted By  
 Question Submitted By :: Vsreedevi
I also faced this Question!!   © ALL Interview .com
Answer
Console applications can take only text based input and 
also can give output in text format only. 

Hence, console applications are best suited for 
applications that should run as a scheduled job.

Also, console applications are the best choice while 
learning a language.
 
0
Banshi
 
 
Answer
consol is used only for web application
 
0
Shekh Irfan Ali
 
 
Answer
Console is used if u want to Create a Windows Based 
application. First Ans is correct.Second is wrong.
 
0
Sonia
 
 
Question
how to get sum of two numbers in vb.net?
Rank Answer Posted By  
 Question Submitted By :: Vsreedevi
I also faced this Question!!   © ALL Interview .com
Answer
Sub Main()
        Dim x, y As Integer
        Console.Write("Enter value of x: ")
        x = Console.ReadLine()
        Console.Write("Enter value of y: ")
        y = Console.ReadLine()
        Console.Write("Sum x+y = ")
        Console.WriteLine(x + y)
        Console.ReadLine()
    End Sub
 
0
Banshi
 
 
Answer
Sub Main()
        Dim x, y, sum As Integer
        Console.WriteLine("Enter two numbers")
        x = Console.ReadLine()
        y = Console.ReadLine()
        sum = x + y
        Console.WriteLine("Sum = " & sum)
        Console.ReadLine()
        '& is used for concatenation
    End Sub
 
0
Sonia
 
 
Answer
imports system.console
sub main()
a,b,c as integer
Console.WriteLine("Ente a:")
ReadLine()
Console.WriteLine("Enter b:")
ReadLine()
c=a+b
Console.WriteLine("The Result is:"+c)
End Sub
 
0
Shamseena
 
 
Question
What is MSIL.
Rank Answer Posted By  
 Question Submitted By :: Nitin Rathi
This Interview Question Asked @   HDFC
I also faced this Question!!   © ALL Interview .com
Answer
MSIL stands for Microsoft Intermediate Language.

When compiling the source code to managed code in dotnet 
environment, the compiler translates the source into 
Microsoft intermediate language (MSIL). This is a CPU-
independent set of instructions that can efficiently be 
converted to native code. Microsoft intermediate language 
(MSIL) is a translation used as the output of a number of 
compilers. It is the input to a just-in-time (JIT) 
compiler. The Common Language Runtime includes a JIT 
compiler for the conversion of MSIL to native code.
 
0
Banshi
 
 
Answer
Microsoft Intermediate Langage.
All .net compilers converts the compled code into MSIL
 
0
Anitha
 
 
Answer
Common Intermediate Language(CIL), previously known as 
MSIL. 
At compile time,a .net compiler converts the source code 
into byte code (CIL)
 
0
Ezhilarasi.k
 
 
Question
Display a roll having minimum marks in two subjects?
Rank Answer Posted By  
 Question Submitted By :: Sonia.sardana
This Interview Question Asked @   Patni
I also faced this Question!!   © ALL Interview .com
Answer
select id from table1 where sub1=(select min(sub1)from
table1)and sub2=(select min(sub2)from table1)
 
0
Priya
 
 
Question
Can we use a crystal report into a another crystal report
Rank Answer Posted By  
 Question Submitted By :: Sasi Kumar
I also faced this Question!!   © ALL Interview .com
Answer
yes, using crystal sub reporting, we can use a crystal 
report in to another crystal report.
 
4
Manoj Kb
 
 
Answer
NO.
 
0
Nitin Rathi
 
 
Answer
yes
 
0
Ranjith Reddy
 
 
Answer
yes using crystal sub reporting
 
1
Sony
 
 
Answer
yes, with the help of Subreport call in our report..
 
0
Pawan
 
 
Answer
Yes, By Insert a sub report
 
0
Siraj Ansari
 
 
Question
in my windows application i have to show excelwork 
sheetwhich is stored in the local system can any one tell 
me the code?
Rank Answer Posted By  
 Question Submitted By :: Savikumar7
I also faced this Question!!   © ALL Interview .com
Answer
I'm giving you the code about export to excel i.e., now i'm 
taking table from database and binding to excel sheet.That 
Excel sheel is on my Local System.
Here i'm using Aspose(its a 3rd Party Tool)
Aspose reduces the code by setting data ,cells etc in Excel 
Sheet.
Its a WebApplication.U can change it to Windows Application.

This code is for Setting the format for Excel Sheet:
public Workbook ExportToExcel(DataSet objDs, string 
strHeader)
        {
            DataTable dtResult;
            dtResult = objDs.Tables[0];

            Workbook excel = new Workbook();
            excel.Worksheets[0].Name = strHeader;

            #region SettingHeaderInformation

            excel.Worksheets[0].Cells
["B4"].Style.Font.IsBold = true;
            excel.Worksheets[0].Cells["B4"].Style.Font.Size 
= 12;
            excel.Worksheets[0].Cells["B4"].PutValue
(strHeader);

            excel.Worksheets[0].Cells
["D4"].Style.Font.IsItalic = true;
            excel.Worksheets[0].Cells["D4"].PutValue
("Dated: " + DateTime.Now.ToLongDateString());

            #endregion

            //Exports data set into excel cells
            Aspose.Cells.Cells exportCells = 
excel.Worksheets[0].Cells;
            exportCells.ImportDataTable(dtResult, false, 5, 
0);

            //This block is to header for exported data 
table.
            Aspose.Cells.Cells sheetCell = excel.Worksheets
[0].Cells;
            for (int i = 0; i < dtResult.Columns.Count; i++)
            {
                if (i != (objDs.Tables[0].Columns.Count - 
1))
                    excel.Worksheets[0].AutoFitColumn(i);

                excel.Worksheets[0].Cells[5, 
i].Style.Number = 49;
                excel.Worksheets[0].Cells[5, 
i].Style.Pattern = BackgroundType.Solid;
                excel.Worksheets[0].Cells[5, 
i].Style.ForegroundColor = excel.GetMatchingColor
(Color.FromName(SystemColors.InactiveCaption.Name));
                excel.Worksheets[0].Cells[5, 
i].Style.Font.IsBold = true;
                excel.Worksheets[0].Cells[5, 
i].Style.Font.Color = Color.White;
                string headerTxt = dtResult.Columns
[i].ColumnName;
                if (headerTxt.Contains(strDesc))
                    headerTxt = headerTxt.Remove
(headerTxt.IndexOf(strDesc));
                else if (headerTxt.Contains(strDesc))
                    headerTxt = headerTxt.Remove
(headerTxt.IndexOf(strDesc));
                excel.Worksheets[0].Cells[5, i].PutValue
(headerTxt);
                if (i < objDs.Tables[0].Columns.Count)
                    excel.Worksheets[0].Cells[5, 
i].Style.HorizontalAlignment = TextAlignmentType.Left;
                else
                    excel.Worksheets[0].Cells[5, 
i].Style.HorizontalAlignment = TextAlignmentType.Right;
            }

            return excel;
        }


In Button we can write this code(its for binding the data 
from database to Excel Sheet):

 protected void Button2_Click(object sender, EventArgs e)
    {
        Aspose.Cells.Workbook workBook = new 
Aspose.Cells.Workbook();
        ExportMethods objExpMethods = new ExportMethods();
        ds = objclass.getpagebal();//calling function from 
businesslayer(table)
        workBook = objExpMethods.ExportToExcel
(ds, "shanti_emp");//shanti_emp is a table name
        workBook.Save("shantiExcel.xls", 
FileFormatType.Default, 
Aspose.Cells.SaveType.OpenInBrowser, Response);
    }

U can convert it according to your convineince.
 
0
Prashanthi
 
 
Question
1234
123
12
1
how to design above pic in vb.net?
Rank Answer Posted By  
 Question Submitted By :: Prob
This Interview Question Asked @   ABC
I also faced this Question!!   © ALL Interview .com
Answer
Sub main()
        
        Dim i, j As Integer
        For i = 4 To 1 Step -1
            For j = 1 To i
                Console.Write(j)
            Next
            Console.WriteLine()
        Next

        Console.ReadLine()
    End Sub
End Module
 
0
Sonia
 
 
Answer
Sub main

 Dim j As String
 Dim i As Integer

  j = 1234

        For i = Len(j) To 1 Step -1
            Console.Write(Mid(j, 1, i))
            Console.WriteLine()
            
        Next
End Sub
 
0
Viji
 
 
Question
What is JIT(Just In Time) and How it works?
Rank Answer Posted By  
 Question Submitted By :: Ateev
This Interview Question Asked @   Infocons , Siemens, Data
I also faced this Question!!   © ALL Interview .com
Answer
Just In Time compiler is another important term in CLR.This 
means that take action as soon as request comes.This term 
is taken form china people.They dontkeep anything in 
inventory. So whenever a resquest for any item arises, they 
purches that item & give to requester; this operation is 
called as Just In Time.
The MSIL, which we canview using ILDASM, is passed to 
CLR,When JIT encounters call to particular method, which 
get converted into Native Code. 
There are three types of JIT Compiler.
Standard JIT
Pre-JIT
ECONJIT
 
3
Pallavi Jadhav
 
 
Answer
JIT is a program which compiles MSIL to machine code, 
without this .net has no path to machine code.
Types:
Standard JIT: It produces highly optimized machine code and 
it caches the code in case it need to access 
again.Compilation of IL to native code is very slow however 
it produces native code very fast. To make it fast machine 
use lot of Ram.
Econo JIT:This is designed for small system which donot 
have lot of RAM.But it Produces the code which is not 
optimal and also it donot cache the code.
 
0
Megha
 
 
Answer
JIT compile the native code, only that part of code will be
compiled which is needed, rest is not compiled untill not
needed.
 
0
Pankaj Arya
 
 
Question
if user enters 1 or 2 or any other number in digit format in
next textbox it should show the answer in word reading
like if enters 12 answer should be twelve
Rank Answer Posted By  
 Question Submitted By :: Shweta
I also faced this Question!!   © ALL Interview .com
Answer
I tried lot but not able to do it.
 
1
Vijay
 
 
Answer
Here is a Program, which can perform upto 99,999 ...
Note: in a vb.net form you have to place one text box named
as  txt1 and one label named as Lab1....
Private Sub txt1_TextChanged(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles txt1.TextChanged
        Try
            If Val(txt1.Text) <> 0 Then
                fun(txt1.Text)
            Else
                Lab1.Text = ""
            End If
        Catch ex As Exception
            MsgBox(ex.Message)
        End Try
    End Sub
    Public Function fun(ByVal t As Integer)
        Dim l As Int16
        l = Len(CStr(t))
        Select Case l
            Case 1
                Lab1.Text = Ones(t)
            Case 2
                Lab1.Text = Case2(t)
            Case 3
                Lab1.Text = Case3(t)
            Case 4
                Lab1.Text = Case4(t)
            Case 5
                Lab1.Text = Case5(t)
        End Select
        fun = Lab1.Text
    End Function
    Public Function Case5(ByVal t As Integer) As String
        Dim L2 As String
        Dim R3 As String
        L2 = Strings.Left(CStr(t), 2)
        R3 = Strings.Right(CStr(t), 3)
        If CInt(R3) = 0 Then
            Case5 = Case2(CInt(L2)) & " Thousand "
        Else
            Case5 = Case2(CInt(L2)) & " Thousand "
            If Strings.Left(R3, 1) = "0" Then
                Case5 = Case5 & " and " & Case2(CInt(R3))
            Else
                Case5 = Case5 & Case3(CInt(R3))
            End If
        End If
    End Function
    Public Function Case2(ByVal t As Integer) As String
        Dim q, r As Int16
        If t > 10 And t < 20 Then
            Case2 = Teens(t)
        Else
            q = Int(t / 10)
            r = t Mod 10
            Case2 = Tens(q) & " " & Ones(r)
        End If
    End Function
    Public Function Case3(ByVal t As Integer) As String
        Dim q1, q2, q, r As Integer
        Dim LabTxt As String
        q1 = Int(t / 100)
        If (t - (q1 * 100)) = 0 Then
            LabTxt = Ones(q1) & " Hundred "
        Else
            LabTxt = Ones(q1) & " Hundred and "
        End If
        q2 = t - (q1 * 100)
        If q2 > 10 And q2 < 20 Then
            Case3 = LabTxt & Teens(q2)
        Else
            q = Int(q2 / 10)
            r = q2 Mod 10
            Case3 = LabTxt & Tens(q) & " " & Ones(r)
        End If
    End Function

    Public Function Case4(ByVal t As Integer) As String
        Dim q As Int16
        Dim r As Int16
        Dim q1 As Int16
        Dim q2 As Int16
        Dim LabTxt As String
        Dim q4 As Integer
        q4 = Int(t / 1000)
        LabTxt = Ones(q4) & " Thousand "
        t = t - q4 * 1000
        If t = 0 Then
            Case4 = LabTxt
            Exit Function
        End If
        q1 = Int(t / 100)
        If q1 = 0 Then
            LabTxt = LabTxt & " and "
            If t > 10 And t < 20 Then
                Case4 = LabTxt & Teens(t)
            Else
                q = Int(t / 10)
                r = t Mod 10
                Case4 = LabTxt & Tens(q) & " " & Ones(r)
            End If
            Exit Function
        End If
        If (t - (q1 * 100)) = 0 Then
            LabTxt = LabTxt & Ones(q1) & " Hundred "
        Else
            LabTxt = LabTxt & Ones(q1) & " Hundred and "
        End If
        q2 = t - (q1 * 100)
        If q2 > 10 And q2 < 20 Then
            Case4 = LabTxt & Teens(q2)
        Else
            q = Int(q2 / 10)
            r = q2 Mod 10
            Case4 = LabTxt & Tens(q) & " " & Ones(r)
        End If
    End Function
    Public Function Ones(ByVal t As Integer) As String
        Ones = ""
        Select Case t
            Case 1
                Return "One"
            Case 2
                Return "Two"
            Case 3
                Return "Three"
            Case 4
                Return "Four"
            Case 5
                Return "Five"
            Case 6
                Return "Six"
            Case 7
                Return "Seven"
            Case 8
                Return "Eight"
            Case 9
                Return "Nine"
        End Select
    End Function
    Public Function Tens(ByVal Que As Int16) As String
        Select Case Que
            Case 1
                Return "Ten"
            Case 2
                Return "Twenty"
            Case 3
                Return "Thirty"
            Case 4
                Return "Forty"
            Case 5
                Return "Fifty"
            Case 6
                Return "Sixty"
            Case 7
                Return "Seventy"
            Case 8
                Return "Eighty"
            Case 9
                Return "Ninty"
        End Select
    End Function

    Public Function Teens(ByVal Que As Int16) As String
        Select Case Que
            Case 11
                Return "Eleven"
            Case 12
                Return "Twelve"
            Case 13
                Return "Thirteen"
            Case 14
                Return "Forteen"
            Case 15
                Return "Fifteen"
            Case 16
                Return "Sixteen"
            Case 17
                Return "Seventeen"
            Case 18
                Return "Eighteen"
            Case 19
                Return "Ninteen"
        End Select
    End Function
 
0
Cherran
 
 
Answer
Private Sub Button1_Click(ByVal sender As System.Object, 
ByVal e As System.EventArgs) Handles Button1.Click
        Me.TextBox3.Text = CInt(Me.TextBox1.Text) + CInt
(Me.TextBox2.Text)
    End Sub
 
0
Sonia
 
 
Answer
Answer 3 is wrong
 
0
Anil
 
 
Question
Hi
I am planning to take interview in VB.net,can any one share 
your interview Questions for a Entry-level job.
Regards
Lina
Rank Answer Posted By  
 Question Submitted By :: Lina
I also faced this Question!!   © ALL Interview .com
Answer
mam, I m engineer student but I faced interviews, if u want 
I can tell u abt the questions I faced during the 
interview. Reply.
 
0
Sonia
 
 
Answer
how to create views in sql with syntax and example
?
create view <Viewname> as
select a as A,b as B,c as C 
from <tablename>
where <whereclause{optional}> order by A
 
0
Praveen
 
 
Answer
How is VB.Net different from VB6??
 In VB.net
           *support inhertiance and Exception handling
           *support disconnected data
 In VB6
           *Doesnt support inhertiance and Exception 
handling & disconnected data
 
0
Praveen
 
 
Question
sql satement for 2nd maximum value
Rank Answer Posted By  
 Question Submitted By :: Mahadev
This Interview Question Asked @   NIIT
I also faced this Question!!   © ALL Interview .com
Answer
author is Table name
ID is column name

select top 1 * from author where ID < (select max(ID) 
from author) order by ID desc
 
0
Murli D
 
 
Answer
select top 1 * from author where phone < (select max(phone) 
from author) order by phone desc
 
5
Archana Chavan
 
 
Answer
Select * from author where rownum=2
order by ID desc
 
0
Rohan Patil
 
 
Answer
select top 1 sal from 
( select top 2 sal from test order by sal desc ) as kk order
by sal
 
0
Cherran
 
 
Answer
select Amount from T2   where Amount = ( select max(Amount)
from T2  where Amount < ( select max(Amount) from T2 ))
 
0
Ramavtar Rajput
 
 
Answer
Rohan answer given by you was not working.....
 
0
Sonia
 
 
Answer
select distinct top 2 salary from employee order by salary 
desc
 
0
Manikandan
 
 
Answer
Select min(Salary)ThirdHighest from employees where salary 
in (Select top 3 salary from employees order by salary desc)
      For nth replace top 3 with top n
 
0
Sunil Nandedkar
 
 
Answer
create table emp with row empsal having the datatype float
and insert some salary
now to get the second max salary
write the sql statement

select max(empsal) from emp where empsal<(select max(empsal)
from emp)
its asubquery
 
0
Avnish
 
 
Answer
select top 1 UnitsInStock 
from products 
where UnitsInStock in (select top 2 UnitsInStock from 
products order by UnitsInStock desc)
 
0
Kaushal Gajjar
 
 
Question
In vb.net how to connect crystal report?
Rank Answer Posted By  
 Question Submitted By :: Vinod
I also faced this Question!!   © ALL Interview .com
Answer
click on solution explorer window right click and add to 
add new item. the window will be displaded select the 
crystal report we have save in any name but extensen is 
used .rpt eg:sss.rpt
 
0
Jaga
 
 
 
Back to Questions Page
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com