|
Hi,
Anyone got source code to change SQl Server startup account to SA.
I need this to be run in my installation.
VB script will be very helpful.
Thanks,
Toms
|
|
|
|
|
SA?? What do you mean "startup account"? The SA account is only used internal to SQL Server.
By "startup account", I take it you mean the Windows service account that the SQL Server runs under. In this case, you'll have to create a Windows account called "SA" and change the service LogOn parameters.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I have a textbox which holds a date and I also have a dropdown box which has 3 values to select.
When the webform is loaded the date field is empty, the dropdown box has a value selected at load time which is Form A. What I want is that when I add a date to the date field then the value in the dropdown box will change to Form B which is in the dropdown list.
The code I have is as follows:
Private Sub dbxStatus_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles dbxStatus.SelectedIndexChanged
End Sub
Private Sub tbxDateSigned_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles tbxDateSigned.TextChanged
If tbxDateSigned.Text = True Then
'dbxStatus.SelectedValue = "Signed Off"
dbxStatus.SelectedValue = "Signed Off"
End If
End Sub
This code doesn't work.
Anyone any ideas?
macca
|
|
|
|
|
do you get an error?
try using changing your if statement to be -
If tbxDateSigned.Text.length > 0 Then
|
|
|
|
|
you may need to make the textbox autopostback equal true. Cause it will only get to that code once you have done a postback. You may want to consider doing this type of thing in javascript.
|
|
|
|
|
Have you any javascript code that might o this type of thing or any resources to get me started on this.
Thanks,
macca
|
|
|
|
|
You would have to do something like described below (havent tested it so you will have to play around a bit to get it working the way you want)
in page load put this line of code
tbxDateSigned.attributes.add("onblur","changeDropDown()")
Then create a javascript function like so -
function changeDropDown()
{
var element = document.getElementById("dbxStatus");
element.selectedIndex = 2;
}
as for resources you can try looking here or just google for javascript -
http://webdevelopment.developersnetwork.com/Search.asp?Category=6[^]
|
|
|
|
|
Help me
I have a trouble again with M.Access. I have a combo-box on a form, and this combo-box has the responsibility on showing the Query which creates the 4-column table, including Company,Name,Address and ClientID.
My purpose is that I want to show this Query in the combo-box in the order A-Z, before the blank company items.
My solution:
I create a query like below:
select .........
from nhanvien
where company is null
union
select .........
from nhanvien
where company is not null
However, the result isn't right like my hope. I think that the reason is because of the order of the ClientID which is the primary key...As a result, the destination query automatically sorts on the ClientID order.
Thinking of the solution :
I don't know how to do to archieve that result. I think so much about the SQL sentence of the above query. I believe that there's another SQL sentence helping me to solve this problem. I'm very happy whether you give me a SQL sentence to do that or another solution to obtain the same result ....
Thanks so much <vtalau>
|
|
|
|
|
vtalau wrote:
select .........
from nhanvien
where company is null
union
select .........
from nhanvien
where company is not null
Try This
<br />
select 1, .........<br />
from nhanvien<br />
where company is null<br />
union<br />
select 0, .........<br />
from nhanvien<br />
where company is not null<br />
order by 1<br />
What I did was add a new column in front of your currently selected data and then sorted by column number 1. That should put all of your null items last.
Have a great day!
j2associates_NO_SPAM_@yahoo.com
|
|
|
|
|
Can anyone tell me whether a webbrowser (MS Internet Control) can navigate to a file included in the vb6 resource file directly without transferring the file to a directory? Thanks.
|
|
|
|
|
|
|
Hello im using MessageBox.Show() to display popup message boxes, i am trying to create a new line for some text im using. I have tryed /r/n and /n both dont work.
How can i create a new line?
Thanks
Oi
|
|
|
|
|
Environment.NewLine
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Thanks worked fine
Im also trying to hide a proccess when its run can you help with this
The code i am using is as follows
Dim startInfo As System.Diagnostics.ProcessStartInfo
Dim pStart As New System.Diagnostics.Process
startInfo = New System.Diagnostics.ProcessStartInfo("C:\test.bat")
pStart.StartInfo = startInfo
pStart.Start()
pStart.WaitForExit() 'Your code will halt until the exe file has executed.
The batch file is shown as it executes how can i hide this?
Thanks
Oli
|
|
|
|
|
Unless you can get a handle on the console window and then hide it in code, I'm afraid I don't know.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
I don't know which one works best, but you can use one (or both) of this:
startInfo.CreateNoWindow = True
startInfo.WindowStyle = ProcessWindowStyle.Minimized
Have fun with it!
|
|
|
|
|
I am building a website using visual studio and an access database. When more than one user is entering data and they submit the info is going to multiple pages. It should only go to the pages that are designated. this does not happen if it is only one user. Is this my dataSets or am I missing something.
|
|
|
|
|
are you using application items?
"People who never make mistakes, never do anything."
My blog
http://toddsnotsoamazinglife.blogspot.com/
|
|
|
|
|
I am not using any that I am aware of
|
|
|
|
|
What do you mean by "the data is going to multiple pages"?
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
The data is going to multiple records in the access database if there are more than one person entering data at the same time.
|
|
|
|
|
could it be a problem with my datasets
|
|
|
|
|
I was wondering if I could insert a file into resource (.RES) file during runtime instead of inserting a file using resource editor at design time. Could anyone help me with this information ? Thanks in advance.
rudysup
|
|
|
|
|
No, you can't.
Since the resources are compiled into the target .EXE at compile time, any changes you make to the file won't be reflected in the target .EXE until you recompile it.
The resource editor is part of the Visual Studio IDE and is not available to your .EXE at runtime. That is, unless your making a Visual Studio add-in...
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|