Showing posts with label function. Show all posts
Showing posts with label function. Show all posts

Monday, March 26, 2012

the connection string property has not been initialized

in one of my classes i have a private function, which sets connection
other public shared functions call this connection
when i try to call the public shared functions say to my form code i get that error
any one ever had that beforemake sure that the SQLCommand object's connection property is set to the SQLConnection object:

string connString = "blah"; //insert REAL conn string here
SQLConnection theConnection = new SQLConnection(connString);
SQLCommand theSQLCommand = new SQLCommand();
theSQLCommand.Connection = theConnection; //This line
..
..

Thursday, March 22, 2012

The handle is invalid

Hi!
I`m stucked with this problem and I don`t know what to do ((
When using CopyFromScreen () function in my Asp.Net application, I reseeve
this error message - "The handle is invalid"
The strange thing is that all working fine on local computer, and this
message only appear on the web.
I have asked on some forums, but nobody could help..I'm sure you've tried a quick google as it also returns several people
asking the same question, with no response as to the problem. Working on
the principle that the only thing that changes is probably the cause - could
it be a security issue; in that it works whilst running localhost but the
privilege is not granted for intranet / intenet. This could be either the
copyfromscreen function, or any function that populates the copyfromscreen()
parameter list. I had a call to a unmanaged DLL that worked under local
host, but not when I released it to the production site (or when other
people accessed the site on my PC). If you access the site built on your PC
with \\<machinename>\<website>\<page.aspx> rather than \\localhost\
<website>\<page.aspx> does it also fail?
Regards,
- Paul.
"Ecuter" <Ecuter@.discussions.microsoft.com> wrote in message
news:9397F62A-37CD-4DEA-8638-78F3DEC2F3B5@.microsoft.com...
> Hi!
> I`m stucked with this problem and I don`t know what to do ((
> When using CopyFromScreen () function in my Asp.Net application, I reseeve
> this error message - "The handle is invalid"
> The strange thing is that all working fine on local computer, and this
> message only appear on the web.
> I have asked on some forums, but nobody could help..
>

Tuesday, March 13, 2012

The handle is invalid

Hi!
I`m stucked with this problem and I don`t know what to do ((

When using CopyFromScreen () function in my Asp.Net application, I reseeve
this error message - "The handle is invalid"
The strange thing is that all working fine on local computer, and this
message only appear on the web.
I have asked on some forums, but nobody could help..I'm sure you've tried a quick google as it also returns several people
asking the same question, with no response as to the problem. Working on
the principle that the only thing that changes is probably the cause - could
it be a security issue; in that it works whilst running localhost but the
privilege is not granted for intranet / intenet. This could be either the
copyfromscreen function, or any function that populates the copyfromscreen()
parameter list. I had a call to a unmanaged DLL that worked under local
host, but not when I released it to the production site (or when other
people accessed the site on my PC). If you access the site built on your PC
with \\<machinename>\<website>\<page.aspxrather than \\localhost\
<website>\<page.aspxdoes it also fail?

Regards,

- Paul.

"Ecuter" <Ecuter@.discussions.microsoft.comwrote in message
news:9397F62A-37CD-4DEA-8638-78F3DEC2F3B5@.microsoft.com...

Quote:

Originally Posted by

Hi!
I`m stucked with this problem and I don`t know what to do ((
>
When using CopyFromScreen () function in my Asp.Net application, I reseeve
this error message - "The handle is invalid"
The strange thing is that all working fine on local computer, and this
message only appear on the web.
I have asked on some forums, but nobody could help..
>