Click here to Skip to main content
15,892,161 members
Home / Discussions / Managed C++/CLI
   

Managed C++/CLI

 
GeneralRe: global access to objects / instances Pin
Richard MacCutchan31-Mar-10 3:46
mveRichard MacCutchan31-Mar-10 3:46 
GeneralRe: global access to objects / instances Pin
KlaasVersteeg31-Mar-10 3:53
KlaasVersteeg31-Mar-10 3:53 
GeneralRe: global access to objects / instances Pin
Richard MacCutchan31-Mar-10 4:25
mveRichard MacCutchan31-Mar-10 4:25 
GeneralRe: global access to objects / instances Pin
KlaasVersteeg31-Mar-10 4:37
KlaasVersteeg31-Mar-10 4:37 
GeneralRe: global access to objects / instances Pin
Richard MacCutchan31-Mar-10 5:53
mveRichard MacCutchan31-Mar-10 5:53 
GeneralRe: global access to objects / instances Pin
KlaasVersteeg31-Mar-10 6:39
KlaasVersteeg31-Mar-10 6:39 
GeneralRe: global access to objects / instances Pin
Richard MacCutchan31-Mar-10 7:12
mveRichard MacCutchan31-Mar-10 7:12 
Questioncannot convert from 'System::Data::DataSet ^' to 'System::Data::DataSet error Pin
m_mun31-Mar-10 0:31
m_mun31-Mar-10 0:31 
Hi,

I have developed a small application. But it gives the above error

It is declared in another class named "CPassword"
SqlConnection ^connect = gcnew SqlConnection();
connect->ConnectionString = ConfigurationManager::ConnectionStrings["SQLConnection"]->ConnectionString;;

SqlCommand ^cmd = gcnew SqlCommand();
cmd->CommandType = CommandType::StoredProcedure;
cmd->CommandText = "GetUserPassword";

DataSet ^dtSet = gcnew DataSet();

try
{
    connect->Open();
    SqlDataAdapter ^adp = gcnew SqlDataAdapter();
    adp->SelectCommand = cmd;

    cmd->Parameters->Add(gcnew SqlParameter("@user_id",SqlDbType::VarChar));
    cmd->Parameters["@user_id"]->Value = userID;

    adp->Fill(dtSet, "Password");
    return dtSet;
}


And I am calling this function from another class

CPassword ^objPassword = gcnew CPassword();
				DataSet ^dtSet = gcnew DataSet();
				dtSet = objPassword->fn_ReturnPassword(txtUserId->Text);


Plese help....

Thanks to all
AnswerRe: cannot convert from 'System::Data::DataSet ^' to 'System::Data::DataSet error Pin
Andreoli Carlo31-Mar-10 3:34
professionalAndreoli Carlo31-Mar-10 3:34 
GeneralRe: cannot convert from 'System::Data::DataSet ^' to 'System::Data::DataSet error Pin
m_mun31-Mar-10 5:37
m_mun31-Mar-10 5:37 
QuestionSide-by-side configuration errors Pin
Lucidation30-Mar-10 10:21
Lucidation30-Mar-10 10:21 
AnswerRe: Side-by-side configuration errors Pin
Andreoli Carlo30-Mar-10 20:33
professionalAndreoli Carlo30-Mar-10 20:33 
GeneralRe: Side-by-side configuration errors Pin
Lucidation31-Mar-10 7:17
Lucidation31-Mar-10 7:17 
GeneralRe: Side-by-side configuration errors Pin
dybs3-Apr-10 18:06
dybs3-Apr-10 18:06 
QuestionExpandable Property in Win Forms Property Grid Pin
zeos626-Mar-10 12:04
zeos626-Mar-10 12:04 
QuestionWhat is this message telling me? Pin
Bert Fegyverneki26-Mar-10 6:00
Bert Fegyverneki26-Mar-10 6:00 
AnswerRe: What is this message telling me? Pin
Ghydo26-Mar-10 7:34
Ghydo26-Mar-10 7:34 
GeneralRe: What is this message telling me? Pin
Bert Fegyverneki26-Mar-10 9:22
Bert Fegyverneki26-Mar-10 9:22 
GeneralRe: What is this message telling me? Pin
Ghydo26-Mar-10 10:25
Ghydo26-Mar-10 10:25 
QuestionDisplay current time in Label control Pin
Lucidation26-Mar-10 5:30
Lucidation26-Mar-10 5:30 
AnswerRe: Display current time in Label control Pin
Luc Pattyn26-Mar-10 5:54
sitebuilderLuc Pattyn26-Mar-10 5:54 
GeneralRe: Display current time in Label control Pin
Lucidation26-Mar-10 6:28
Lucidation26-Mar-10 6:28 
GeneralRe: Display current time in Label control Pin
Luc Pattyn26-Mar-10 6:44
sitebuilderLuc Pattyn26-Mar-10 6:44 
GeneralRe: Display current time in Label control Pin
Lucidation26-Mar-10 7:07
Lucidation26-Mar-10 7:07 
GeneralRe: Display current time in Label control Pin
Ghydo26-Mar-10 7:37
Ghydo26-Mar-10 7:37 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.