|
Okay, after I removed my varibles at the end of my stringurl, it functioned, am I writing something wrong hterE?
|
|
|
|
|
Do you really want the apostrophes around the values in the query string? They will end up as part of the value when you read the values from the query string.
If any of the values in the query string may contain any characters that has a special mening in an url, they have to be url encoded (using the Server.UrlEncode method).
If you really want the apostrophes in the values, you have to encode them as \' when putting the url in the Javascript string, otherwise the first apostrophe in the url will end the string.
And on a side note: Why on earth are you using string concatenation when you have a StringBuilder? Use the Append method to add each string to the StringBuilder instead of first concatenating strings and then adding them.
sb.AppendLine("<script language=\"javascript\" type=\"text/javascript\">");
sb.AppendLine("window.open('").Append(url).Append("','").Append(windowName).Append("','" ).Append(openParams).Append("');");
sb.Append("</script>");
---
single minded; short sighted; long gone;
|
|
|
|
|
I did use string bulider. Do I need to use string bulider to bulid the url string?
|
|
|
|
|
"String bulider does not contain a defination for appendline."
|
|
|
|
|
Right. That is only available in framework 2.0.
Use .Append(...).Append(Environment.NewLine) instead.
---
single minded; short sighted; long gone;
|
|
|
|
|
Ibuprofen wrote: I did use string bulider.
Yes, but you used string concatenation to create strings to add to the StringBuilder. There is no reason to create the intermittent strings as you can add each string directly to the StringBuilder.
Ibuprofen wrote: Do I need to use string bulider to bulid the url string?
You don't have to use a StringBuilder at all if you don't want to.
---
single minded; short sighted; long gone;
|
|
|
|
|
Guffa, as I test this, I will let you know if it works. I just wanted to say Thank you, you are the first person to ever give me a decent response on code project.
|
|
|
|
|
I never did get this to work, however, I just used a Session Variable.
Thanks for your time Guffa!
|
|
|
|
|
Hi
I am doing design document update for my code, I am in need of putting class diagram and class description. I could able to create class diagram from VS studio, but i am not able generate class descriptions (like variable_name type modifier description) for all the variables,properties and functions. I can able to see those details by right click on the class diagram and class view details, but it is not allowing me to copy all the details at a time. But i am able to copy one at a time. Is there any simple way to get all class description as like as shown in class details window. (I am working in C#). so that i can copy and paste it in the document. ( i very much required this, because i have 100s of classes and its variables
thanks
srini
|
|
|
|
|
hello.... i wanted to read an image from a scanner into a picture box using c#, but am kindof afraid of port programing. would any one plz help me in doing so
thankyou
haseeb
|
|
|
|
|
You might see if the scanner you are targeting has API commands that can be called from the .NET program.
Regards,
Thomas Stockwell
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.
Visit my homepage Oracle Studios[ ^]
|
|
|
|
|
it supports twain. i believe that it can be called but how to call it, i don't know and how am i gonna see if its api commands can be called from .net or not..
haseeb
|
|
|
|
|
Google It
Regards,
Thomas Stockwell
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.
Visit my homepage Oracle Studios[ ^]
|
|
|
|
|
I am working in the compact framework.
I have an ATL/COM library that creates a bitmap. I need to pass the bitmap to a C# program and display it. We have tried creating the bitmap in C# with GDI methods then used the APIs for CompatibleDCs, selectobject, getHdc, etc and passed the DC to the ATL object. On returning it from the ATL object I get ExceptionHandling errors relating to memory when I try to get a bitmap I can use in managed code. We have been able to pass the DeviceContext and draw directly on it but I want to retrieve a bitmap that I can cache as a member variable in my class.
Has anyone successfully passed bitmaps back and forth between managed and unmanaged code?
|
|
|
|
|
when i run my C#.net windows form means the following error is display.
"The type or namespace name 'keys' could not be found (are you missing a using directive or an assembly reference?)"
how to clear this error?
|
|
|
|
|
Someplace in your code you either have using keys or in the code you have keys.
You need to provide a reference to the dll that the keys namespace / object exists.
Go to references right click and add a reference.
Or remove the code that has keys in it if it is not needed.
Ben
|
|
|
|
|
Remember that C# is case-sensitive. You have to write Keys if you're referring to the framework's built-in class.
|
|
|
|
|
Hi,
I have already made this but i just cant do it again!! I'm missing something.....
What do i need to do in order to have a ok button to close a form?
What i have done was:
- Create a button in a form and give it a name (btnOk)
- Go to form properties and select btnOk in AcceptButton property
What do i need to do more?
Thx,
Nuno
|
|
|
|
|
Do you open the form using ShowDialog ?
---
single minded; short sighted; long gone;
|
|
|
|
|
Yes, i open it using ShowDialog()
Nuno
|
|
|
|
|
Add an EventHandler for this button click event and call
this.Close();
in that method.
Cheers,
Suresh
|
|
|
|
|
Hi,
Doing that the form closes but there isnt a result from it.
Nuno
|
|
|
|
|
Create a button.
Double click it in the sub section (function that appears), type this
this.Close();
Keshav Kamat
India
|
|
|
|
|
Hi,
Visual studio is saying that it doesnt know the method close.
You know, i'm thinkinhg this is very strange since i have already done something which i only had to tell in the mainform who was the accept button, and now i can't do it for this case.
Thx,
Nuno
|
|
|
|
|
Hi
In my C# project i use COM library, and want to invoke some properies of COM objects
dynamicly (using Reflection), but i can;t do this in standard way (because every com object have
RuntimeType Type and not Type of COM class) How i can to do this.Thank;
|
|
|
|