|
You can download the free version of management studio express from MS. It works with both 2000 and 2005.
Your version should work too, but I don't believe the ATTACH method was available in 2000. In your case you would need to copy the DB files to the Data directory the SQL will look in.
e.g. C:\Program Files\Microsoft SQL Server\.....
|
|
|
|
|
I have copied the DB files(.mdf) to the data directory but the database didn't appear in the
SQL 2000 Server Enterprise Manager.Then I tried using Attach database but it doesn't work too(I got an error telling me:couldn't find row in sysindexes...).
It seems that the last choice remains to me is downloading management studio express from MS.
I am too late but i will never give up
|
|
|
|
|
I'm retrieving data from the database and try to pass it on to a javascript function so I can process it. I get a javascript error when I try to pass the value.
Here is my code:
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim val As String = CType(FormView2.FindControl("ImgList"), HtmlInputHidden).Value
MsgBox(val)
Dim script As String = ""
script = ""
script &= "var str = String(" & val & ");"
script &= "alert(str);"
script &= "setImageArr(" & str & ");"
script &= ""
Page.ClientScript.RegisterClientScriptBlock(Me.GetType, "SetList", script)
End Sub
When I check via MsgBox the right value shows, but it want show in the javascript.
Any suggestions.
Thanks
|
|
|
|
|
The error is right here :
TAK78 wrote: script = ""
script &= "var str = String(" & val & ");"
script &= "alert(str);"
script &= "setImageArr(" & str & ");"
script &= ""
First of all, use a stringbuilder !!
<br />
StringBuilder sbScript = new StringBuilder();<br />
sbScript.Append("<script language='javascript' type='text/javascript'>");<br />
sbScript.Append(Environment.NewLine);<br />
sbScript.Append("alert('");<br />
sbScript.Append(str.Replace("'", "\\'"));<br />
sbScript.Append("')");<br />
sbScript.Append(Environment.NewLine);<br />
scScript.Append(setImageArr('");<br />
sbScript.Append(str);<br />
sbScript.Append(')");<br />
sbScript.Append("</script>");<br />
|
|
|
|
|
TAK78 wrote: I get a javascript error when I try to pass the value.
Standard question #2:
What error message do you get?
TAK78 wrote: script &= "setImageArr(" & str & ");"
As you have no variable named str in your server code, a new empty variable is created. This code will therefore not put any parameter in the Javascript code. You should have Option Explicit in your code to protect you from inadvertently create variables.
You have to put quotes or apostrophes around the string value in the Javascript code. Also you have to encode the value properly, or you will have problems with certain characters.
Dim script As String = _
"<script type=""text/javascript"">" + _
"var str='" + val.Replace("\","\\").Replace("'","\'") + "';" + _
"alert(str);" + _
"setImageArr(str);" + _
"</script>"
---
single minded; short sighted; long gone;
|
|
|
|
|
Thanks a lot works perfect now!!!
So problem was that you have to encode the special characters before you pass it on, right?
Thanks for the help and advice
|
|
|
|
|
And still use a stringbuilder for string manipulation... is works a lot faster :->
|
|
|
|
|
|
Eduard Keilholz wrote: And still use a stringbuilder for string manipulation... is works a lot faster
Not if you write the code as I did, which produces a single call to String.Concat.
---
single minded; short sighted; long gone;
|
|
|
|
|
TAK78 wrote: So problem was that you have to encode the special characters before you pass it on, right?
The main problem was that you didn't have any apostrophes around the string value.
---
single minded; short sighted; long gone;
|
|
|
|
|
Do you mean if the textbox where users can enter a search string is focussed, or just at any time when a user presses the return button on the keyboard...
|
|
|
|
|
after entering the search word in text box i want to perform the search by pressing enter(on keyboard) which i can't do
by clicking the search button with mouse i am able to search but i want to do search by pressing enter on the keyboard thnx for responding
like in google when we enter some word to search and press enter on keyboard it returns the search results like that
-- modified at 10:47 Thursday 19th July, 2007
|
|
|
|
|
Have you tried setting the textbox's AutoPostBack property to true?
|
|
|
|
|
s i enabled it but do i have to do something so that it activates the search
rightnow if i press enter the same page is displaying but i want the search results page to be displayed when enter is pressed
its displaying the search page if i click on search button
when someone clicks the "search" button i am enabling button_click EVENT where i am taking to the search results page
so i have to enable the button_click when some1 presses the enter on keyboard
-- modified at 11:04 Thursday 19th July, 2007
|
|
|
|
|
AH!! That's a difficult way to describe your problem...
erhm... If you remove the code from your button click into a seperate function and call that function from your button click...
<br />
private void DoSearch()<br />
{<br />
}<br />
<br />
button_click()<br />
{<br />
DoSearch();<br />
}<br />
You only have to call the same function from your textbox's TextChanged event.
Doubleclick your textbox to generate a TextChanged event handler, and within that event call :
<br />
DoSearch();<br />
|
|
|
|
|
|
Hey guys,
I'm about to develop a webservice, and ofcourse want to secure that properly. I'm not really into webservice security though, thus posting this question. I installed Web Services Enhancements 3.0 which should be capable of helping me out here.
My first goal is to crypt the messages sent from and to the webservice. We don't have an SSL certificate and do not intend to buy one. How can I set up a fairly good encrypted communicating webservice?
I've read this[^] fine document, not helping me out a lot because it assumes I really know everything about webservices.
Anyone??
|
|
|
|
|
Hi I want to learn ASP.Net form home. Are there any free video tutorials availble on internet ... Please help me
Thanks In advance
|
|
|
|
|
msdn2.microsoft.com/en-us/asp.net/default.aspx on the right hand side u have top webcasts u can find many video tutorials all the best
|
|
|
|
|
|
Hi
In my one of the application i am creating check box dynamically. for that
purpose i am using html web server control. i am dynamically creating
checkbox and it to table row and cell but i need only 3 checkbox per row
when 4 checkbox added to the page it should come to next row how i can do
this.My code is as follow.Please help me to solve this.
While dr.Read<br />
Dim chkbox As CheckBox = New CheckBox<br />
chkbox.Text = dr(0)<br />
chkbox.CssClass = "pagetext2inside"<br />
chkbox.ID = "chklang" & i<br />
Dim tabcell As TableCell = New TableCell<br />
Dim tabrow As TableRow = New TableRow<br />
<br />
tabcell.Controls.Add(chkbox)<br />
tabrow.Controls.Add(tabcell)<br />
chktable.Rows.Add(tabrow)<br />
<br />
<br />
i = i + 1<br />
End While<br />
dr.Close()
Rahul
|
|
|
|
|
Hi Rahul,
I am not good in vb
I think you can write the same as
Dim tabrow As TableRow
i = 0
While dr.Read
Dim chkbox As CheckBox = New CheckBox
chkbox.Text = dr(0)
chkbox.CssClass = "pagetext2inside"
chkbox.ID = "chklang" & i
Dim tabcell As TableCell = New TableCell
if (i mod 3)= 0 then
if tabrow.Cells.Count > 0 then
chktable.Rows.Add(tabrow)
end if
tabrow = New TableRow
end if
tabcell.Controls.Add(chkbox)
tabrow.Controls.Add(tabcell)
i = i + 1
End While
dr.Close()
if tabrow.Cells.Count > 0 then
chktable.Rows.Add(tabrow)
end if
Ullas Sadanandan
|
|
|
|
|
1. How can I get the url of the webservice it is running?
a. within the page from web service is being invoked
b. from Within web service
I have web service on multiple servers from it can be invoked. Based on where it is running I have different logic to execute.
2. I want to pass certain information to the web service that can be used between my all web methods. I do not want to pass all the information in webmethods parameters like
<webmethod()>_
Public function MyWebMethod_1(ByVal param1 as string....ByVal paramN as String) As String
...
End function
<webmethod()>_
Public function MyWebMethod_N(ByVal param1 as string....ByVal paramN as String) As String
...
End function
Any idea how can I do this? Can I have properties in web services? Yes, How?
|
|
|
|
|
in datagrid how images are displayed
|
|
|
|
|
take image control in ItemTemplate and pass image path to src property
Best regard
Pathan
GOD HELP THOSE WHO HELP THEMSELVES
|
|
|
|