|
.netman wrote: Still an obnoxious programmer
At least I can do my job. Just in case you are interested I provided you a link that will help you learn what your error message means. That should in turn help you solve your problem yes?
led mike
|
|
|
|
|
OK the link was useless, I know what well formed means I just wondered if anyone knew the correct syntax to put variables into the hyperlink field .
You may have seen that I have posted help to other so I expected someone to maybe help me, that is why I posted on this forum.
|
|
|
|
|
I don't use inline server code like that, I think it's garbage. I would use code behind to generate the URL string and assign the value to the controls property.
Anyway, this might help you.[^]
led mike
|
|
|
|
|
This gets a bit convoluted. you cant use " for the attribute and " inside the Eval statement.You also cant use Eval twice like that in a server tag.
Lets hit those 2 things one at a time:
Text="<%# Eval("Value") %>"
must be
Text='<%# Eval("Value") %>'
note the use of ' for the attribute - this allows you to use the " in the Eval statement.
For the other one, you have to evaluate the whole link at runtime so:
NavigateUrl="Page.aspx?qtynewvar=<%# Eval("Value") %>&stringname=<%# Eval("Value") %>&stringname=<%# Eval("Value")%>"
must become:
NavigateUrl='<%# "Page.aspx?qtynewvar=" + Eval("Value") + "&stringname=" + Eval("Value") + "&stringname="+ Eval("Value") %>'
(again, note the use of ' for the attribute)
oh, and I as much as I tell people to use google when they are lazy, IMO this is one of those weirdnesess that you just pick up through experience. However, as always if you google the exact error message you will find the answer!
|
|
|
|
|
Great answer thanks that worked!
Just what I was looking for.
cheers

|
|
|
|
|
Hi everyone,
I need to create runtime RadioButtons with C#, and I want to set the width of the label (or of the entire control).
This way it's not working:
RadioButton rdb = new RadioButton();
rdb.Width=300;
Suggestions?
What am I doing wrong?
Thanks!
|
|
|
|
|
Have you tried setting the AutoSize property of the RadioButton to false?
By your code, I'm assuming you're not using ASP .Net, and that you are using C#; if that is the case, you might want to put this question in the C# forum next time. Otherwise, I apologize for my assumption.
I hope this helps.
|
|
|
|
|
Okk...I'm using C#, you're right but I'm developing a web application, so I thought it was better to post here, otherwise i could have got an answer about windows applications...
Yes, I tried to change the autosize to false, but it didn't work...
Don't know what I have to think...
Anyway, Thanks!
|
|
|
|
|
I apologize for my assumption; you've posted in the right area.
If you look at the source code in HTML after ASP .Net creates the radio buttons, it actually creates two HTML elements, an <input> tag (which creates the button) and a <label> tag (that contains the text linked to the button). You will most likely have to find a way to get CSS attached to the <label> element.
I hope this helps.
|
|
|
|
|
Its been a long time been out of touch with .NET and C# for me, and am trying to come back.
I remember having worked with RESX files in ASP however not sure when was this feature introduced?
Was it ASP .NET 1.1 or 2.0?
Help is appreciated!
------------------------------------
Vision is the ability to see the invisible
|
|
|
|
|
Spykraft wrote: Help is appreciated!
Ok, it was introduced in 1.1. Why does it matter?
led mike
|
|
|
|
|
Thanks!
led mike wrote: Why does it matter?
Cus I have to edit a read me file which i wrote last year! For some reason I have mentioned it used 2.0 even though i used VS 2003 to create the application!
------------------------------------
Vision is the ability to see the invisible
|
|
|
|
|
Hi,
I have a page with some info on it, including a customer details form. When the user clicks the submit button, they are redirected to a second page* (using the button postbackurl property).
On this new page i wish to recall the data the user input into the form. I know that i should use 'Requet.Form["field name"]', for this but i dont know what the field will be called. At present iam using this:
<code>Literal1.Text = Request.Form["TextBox2"];</code>
However this is not returning any text.
Please can you sgive me some idea of where im going wrong.
Many Many Thanks!
<small>*I have to do this so please dont suggest i do it differently. Thanks.</small>
|
|
|
|
|
Find any info on ViewState or Session objects
|
|
|
|
|
string sttestbox = textbox1
Session["Sessioname"] = sttestbox;
|
|
|
|
|
I cant really use sessions as i am using them for a whole load of orders etc.
Thanks for the suggestion.
|
|
|
|
|
creat an order object class.
fill the class for each order
as soon as one order is filled add the order to an ArrayList.
In the session object you can objects. So you can add an ArrayList to 1 session0bject.
In the second page cast that session object to an ArrayList and you can reach your data.
|
|
|
|
|
This is a great tip for something else I was working on. Thanks for posting it digimanus.
digimanus wrote: creat an order object class.
fill the class for each order
as soon as one order is filled add the order to an ArrayList.
In the session object you can objects. So you can add an ArrayList to 1 session0bject.
In the second page cast that session object to an ArrayList and you can reach your data.
|
|
|
|
|
Care to shed any more light, with reference to my question?
Thanks.
|
|
|
|
|
Friend ,..You can use 'request.querystring' method to call the
second page's value to other ...
|
|
|
|
|
I dont really want to use QueryString as its open to abuse.
Thanks anyway.
|
|
|
|
|
Hi dear,
Have u tried using Server.Transfer and HttpContext
just see the below exa.
there is one textbox in yr form and u want that textbox value in another page. for that do the following..
HttpContext.Current.Items("txt1") = Txt1.Text;
Server.Transfer("anotherPage.aspx");
-------------- To access data in anotherPage.aspx
string txt1 = HttpContext.Current.Items("txt1").toString();
I hope it will help u..
regards
Rana Krishnraj
|
|
|
|
|
Rana,
Thanks for the suggestion. I have 6 textboxes i need cross page access to. Will this work with all 6 textboxes?
Also do i need to dispose of the items in Context after use?
Thanks!!!
|
|
|
|
|
Hi,
Yes of-course it is possible for all 6 textboxes. for demo purpose i write the code for one textbox only, ok.
after using of Context no need to dispose them, but according to yr requirement u have to clear HttpContext.
Regards,
Rana Krishnraj
|
|
|
|
|
Hi
can anyone help me how to post two different files of different formats from one page to another page using HTTP Post.
Thanks in Advance
modified on Wednesday, April 2, 2008 1:08 AM
|
|
|
|