|
Which line ? The error means what it says, you should at a minimum always check a value before using it as an index, to make sure it's within the correct range.
Member 1832081 wrote: odsVisitsEdit.SelectParameters("VisitID").DefaultValue = varVisitid
I'd say either varVisitid is not a right value, or VisitID is not found. You should break this code down and write it so it is safe. Then try to work out why it's failing.
Christian Graus
Driven to the arms of OSX by Vista.
"! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums.
I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp
|
|
|
|
|
it's telling me it for this line
<pre> dviewVisitsEdit.DataBind()
Even if I take that out I still get it.
I have narrowed down the issue a little further.
If I only have one row in my top level Gridview - gvpatientname it works fine.
If I have 2 rows in the gvpatientnm grid Then the selected row for the embedded gridview -gvvisitdetails
stays selected if I change from one patientname row to another. So the gvvisit could have two rows selected under two patients.
Let me try to illustrate
gvpatientnm
PatID Name
1 Joe Jones
gvvisitsDetails
PatID VisitID
1 1234
1 6783
then for another patient the gvpatiennm gridview and gvvisit gridview are repeated
gvpatientnm
2 Mike Johnson
gvvisitsDetails
PatID visitid
2 4747
Here's a link to a screen shot of the grid
<GridView Pics (opens in new window)
Notice how both edit buttons are able to be selected, this causes a problem when I try to send the selected value to
my detailsview - dvvisitedit.
I am not sure how the best way to handles this is??
Help is appreciated.
Thanks
|
|
|
|
|
Got it to work
Dim gv As GridView = DirectCast(sender, GridView)
odsVisitsEdit.SelectParameters("VisitID").DefaultValue = gv.SelectedValue
dviewVisitsEdit.DataBind()
dviewVisitsEdit.ChangeMode(DetailsViewMode.Edit)
ModalpopupVisits.Show()
|
|
|
|
|
I want to create Tree through Database.........For Root nodes i wrote this code....can anybody guide me how to make child nodes.
i hav category(cat_id,cat_name),
sub category(sub_cat_id,cat_id,sub_cat_name) tables
under category node i have to fill subcategory names as child node
con.Open()
cmd = New SqlCommand("select cat_id,cat_name from tbl_category order by cat_name", con)
dr = cmd.ExecuteReader()
While dr.Read()
cat = New TreeNode()
cat.Text = dr("cat_name").ToString
cat.Value = dr("cat_id").ToString
TreeView2.Nodes.Add(cat)
End While
dr.Close()
con.Close()
|
|
|
|
|
Use this query to get the results
SELECT
Category.cat_id, Category.cat_name, SubCategory.Sub_cat_id, SubCategory.sub_cat_name
FROM
Category
INNER JOIN SubCategory ON
Category.cat_id = SubCategory.cat_id
ORDER BY
Category.cat_id
Now, loop through the results and while the catid is same add the subids as child nodes
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
2).An application using cookie authentication was working fine on another server. When moved to a new server cookie authentication is not working correctly.Which one of the following is the likely explantion of the above problem?
a).The new IIS server is not configured to allow anonymous access.
b).passport authentication is not correctly configured
c).The users are not correctly entering their password
d).The IP address of the new server does not match the prior server IP address.
e).SSL is not properly configured
Thanks,
L
|
|
|
|
|
Have you had your job interview yet ? Some of these options are ridiculous, and if you don't know the answer, you don't deserve the job. Can you tell us which ones can't possibily be the issue, and why ?
Christian Graus
Driven to the arms of OSX by Vista.
"! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums.
I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp
|
|
|
|
|
I am thinking of either it could a or e. I found this some online site.
|
|
|
|
|
OK, I'd guess at a, and the ones in the middle, included the ones that seemed stupid. If you just found this on some site, I'm not sure why you're asking, but the question would be, why would this stop cookies from working ? I would assume that if you need cookies to login, and the site does not allow anonymous access, that neither condition can be met before the other is. But, I admit to not really knowing for sure. I could just see that some of the answers given were obviously not right.
Christian Graus
Driven to the arms of OSX by Vista.
"! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums.
I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp
|
|
|
|
|
Hello,
I am working on an asp.net page and I have a multiline text box that displays some text. I want the user to have to scroll all the way to the bottom before I display a checkbox for them to continue. My question is how can you tell if the scroll bar is at the bottom?
|
|
|
|
|
Have a look here[^], maybe it will help you.
only two letters away from being an asset
|
|
|
|
|
Thanks for the reply. Well, I don't think I want the position of the browser window. I need to know when a user has finished scrolling to the bottom of the textbox control. So, I think I'd need the scrolling locations inside the textbox control only. I also don't know how to trigger this.
|
|
|
|
|
problem: I use 1 table book on SQL Server 2005
table book of school:
1. idBook
2.idPublish
3.idAuthor
4.tittle
5.introduction
6.price
table in the book include books have tittle as follows:
1. Văn học việt nam cận đại
2. Tự học tiếng anh
3. tự học lập trình SQL 2005
4. Văn học nước ngoài
5. phát triển website với .net 2005
requirements:
They built storeduce 1 to load data from sql on dataset
storeduce structure as follows:
...
@txtSearch nvarchar (200)
Begin
Select ...
from book
where ...
end
...
I want:
@txtSearch='Văn học cận đại'-->2 record:Văn học việt nam cận đại, Văn học nước ngoài
@txtSearch='lập trình SQl 2005'-->2 record:tự học lập trình SQL 2005,phát triển website với .net 2005
Thanks you!
|
|
|
|
|
May i ask what is "storeduce"?
Btw, are you searching for "LIKE"?
SELECT idBook FROM Book WHERE title LIKE N'%van hoc%'
|
|
|
|
|
I can't even make out what you're trying to ask
only two letters away from being an asset
|
|
|
|
|
In which language Stored Procedure is called storeduce???
Anyways, Lemme give it a try.
SELECT * FROM book WHERE title like @txtSearch
This is the most I(or probably anyone in this world) can do for you.
Buddy, You really need to ask your question properly.
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
I want to make a guestbook for users visiting my site.
I have some textboxes wherein user enters his name, email address, & a message. At the bottom there is a button called "post". As soon as a user fills up the textboxes & clicks post buuton. I want the message to be shown on my page along with their details.
Does anybody have an idea how to do this? Or How can I send a mail filled with form item details.
|
|
|
|
|
Posting user supplied data to a webform? Gee, I don't know, sounds rather difficult
Get an ASP.NET book, drop it on the floor and look at the page that is open. I bet you'll find the answer.
only two letters away from being an asset
|
|
|
|
|
i am a 100 pc network adminstrator. i want to safe soem paper and tone so i was thinking to implement a solution to that; force print preview option before printing on all types of documents. i saw posted the "PrintPreview_scr" code but i don't know how to adopt it to my domain users.
thanks a lot for any reply
|
|
|
|
|
This is the asp.net forum. I think you meant to post this elsewhere.
I didn't get any requirements for the signature
|
|
|
|
|
marjanaprifti wrote: am a 100 pc network adminstrator. i want to safe soem paper and tone so i was thinking to implement a solution to that; force print preview option before printing on all types of documents. i saw posted the "PrintPreview_scr" code but i don't know how to adopt it to my domain users.
How does it related to ASP.NET ?
|
|
|
|
|
Hi all,
Is it possible to get access to a query string when its hidden from view? Google's query string would be easy to do as you can capture the value of 'q' from the string, change it then set it away searching as its visible.
It doesn't matter to the application that the user can't see (or does not need to see) the query string but how can I capture it, manipulate it behind the scenes than pass it to be processed?
Cheers
Scott
|
|
|
|
|
You can use hidden variables.
You can also use context variable with Server.Transfer method for moving one page to another.
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
Thanks for that, didn't know you could do that.
Will that also grant access to the query string as well? Will need to see it to extract the parameter names from the query string?
|
|
|
|
|
Hello
can we hide any column into grid view where we can store any id of particular item which can be use for further operation
plz any one guide me
if any body has its samples solution plz give ge
|
|
|
|