|
It appears that, new for server 2012, Windows is delaying the start up of any application that is in
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run
or in the profile specific or global start up folder
C:\ProgramData\Microsoft\Windows\Start menu\Programs\StartUp
If you haven't seen this, create a shortcut to calc.exe on a 2008 or 2008r2 box, put it in the start up folder log out and then log in, it should pop up immediately. Try that on a 2012 box and you can could to 5 or 10 (depending on how fast you count) before it will appear, starting after the desktop has loaded. I would like to know what this specific feature is called, if it can be altered and if not, how to get around it within my code?
Thanks!
|
|
|
|
|
I assume you're talking about "seconds" when you said "Try that on a 2012 box and you can could to 5 to 10 ... before it will appear".
MS did not put any kind of delay in there. Explorer is just taking that long to get around to processing the command lines found in the registry.
You probably have some other process running that is thrashing the disk, preventing Explorer from launching the command lines in a timely manner.
|
|
|
|
|
Yes, I did mean to type "Try that on a 2012 box and you can count the 5 or 10" implying counting along with a clocks second hand.
This is on a test server, with a fresh image that is very barren, I'm pretty sure this is by design, or at least something has been tweaked to enable this, and that's what I'm looking for.
|
|
|
|
|
You're chasing a ghost.
I'd be looking for what the O/S is doing during that time and fixing that. There's nothing added that intentionally delays the launch of anything in the Run key.
One rather large culprit is the Indexing Service. Also, Server installations of Windows will devote more resources and time to background services and processes over the UI, further limiting the responsiveness of being logged into the console.
|
|
|
|
|
turbosupramk3 wrote: how to get around it within my code?
Not exactly sure what "code" you mean but as a best guess maybe you really want to know how to design what is called "kiosk" software which requires a number of different things in different parts of windows to be effective. So researching that might help.
|
|
|
|
|
Here is the answer, I used
Quote: HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\UserInit. This points to the program C:\WINDOWS\system32\userinit.exe and the entry ends with a comma. Other programs can be started from this key by appending them and separating them with a comma.
to get my task bar to launch immediately. With 2012 it appears that Microsoft is staggering the way this order listed below iterated through, instead of cycling through it as fast as the processor will allow, as a performance enhancement.
http://social.technet.microsoft.com/forums/windows/en-US/99ea6078-00b2-472a-9a6f-888d0a992964/customize-the-winlogon-process[^]
Quote: If you mean, which keys can be used to start application programs, this is the startup sequence of the major registry keys, starting immediately after bootmgr has been read and ending with the program shortcut entries in the two Startup folders.
1. HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\BootExecute. This can include instructions to schedule the running of chkdsk but not user programs.
2. Services start next, followed by the RunServicesOnce and RunServices registry keys (if present)
3. User then logs on to the system
4. HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\UserInit. This points to the program C:\WINDOWS\system32\userinit.exe and the entry ends with a comma. Other programs can be started from this key by appending them and separating them with a comma.
5. HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\Shell. This should contain just one entry, explorer.exe.
6. Program entries in these 2 registry keys for ALL USERS start next:
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run and \RunOnce
7. Program entries in these 2 registry keys for CURRENT USER start next:
HKCU\Software\Microsoft\Windows\CurrentVersion\Run and \RunOnce
8. Programs in the Startup Folders of All Users and Current User are started last of all.
Important programs like antivirus and firewall start early in the sequence as Services. The icons that appear in the Notification Area (bottom right of the screen) are just their user interfaces, i.e. options and preferences.
The additional location for 32-bit software in a 64-bit computer is HKLM\SOFTWARE\Wow6432Node and HKCU\Software\Wow6432Node.
|
|
|
|
|
I am newbie in asp.net
Using EF , I am fetching movie type from db.
Don't no how to display in dropdown as well as if movietype get edit using EF how it will show selected or saved dropdown selected value?
code
@Html.DropDownListFor( m => m.Parent, new[] { @Value = newViewBag.MovieType } }
|
|
|
|
|
Member 10324020 wrote: asp.net
You might have a better chance of getting a response if you posted your question in the ASP.NET forum.
|
|
|
|
|
Thanks for advice please let me know asp.net forum or any place here for help.thanks
|
|
|
|
|
Hi,
Here is the code that can be used on cshtml pages
@Html.DropDownListFor(model => model.movietypeID, new SelectList(Model.movietypes, "Key", "value"), "--Select--")
You need to bind the movietypes variable as a dictionary from the database.
On the time of editing, you need to fetch the value of movie type selected at the time of creation and assign it to movietypeID, and again you will have to bind the movietypes variable from the database.
|
|
|
|
|
i want to create a program that would download all the image from an open web page in c. how would i go about doing such a thing?
|
|
|
|
|
|
Hello All.
Hello all.
can we use progressbar to show connectivity in c#
Hello all i am making a win app that uses internet connection for being online.
Here is the piece of code.
using agsXMPP;
xmppclientconnection test = new xmppclientconnection();
private void Button_Click(object sender, RoutedEventArgs e)
{
test.Server = "jabber.com";
test.ConnectServer = "o.nimbuzz.com";
test.Open(textBox2.Text, textBox9.Text, textBox3.Text );
test.OnLogin += new ObjectHandler(connected1);
}
private void connected1(object sender)
{
if (base.InvokeRequired == true)
{
base.BeginInvoke(new ObjectHandler(connected1), new object[] { sender });
}
else
{
textBox1.BackColor = Color.Green;
textBox2.BackColor = Color.Green;
textBox3.BackColor = Color.Green;
listBox1.Items.Add(textBox1.Text + " → CONNECTED ✓");
}
}
i want to add a progress bar that must start on button1 click and stop on textbo color change event.
|
|
|
|
|
You don't stop the ProgressBar on an event. That's just relying on a house of cards.
If you need the ProgressBar stopped, explicitly do it from the code that determines if it should be stopped.
|
|
|
|
|
Member 10579673 wrote: i want to add a progress bar that must start on button1 click and stop on textbo color change event. I vote for "no", with this argumentation:
A progressbar is like a way of showing the user how the computer counts to 10, or wait until something is 100% - it shows progress. It does not start on a click and end with a random event; there's hardly any progess you can report in between. How would you know when to set the progressbar to, say, 50%?
I can show a progressbar if I know how much things I have to do; say I modify 50 records, I set the max to 50 and update the progressbar every second. That's progress.
Waiting until "something happens" is different; if you show a progressbar, set the max to, say, 100, and increment every second - your bar will overflow after 101 seconds. It's common to show an animation at that stage. We use animations, because they prove that the application is still responding. Sometimes that's all you can do, tell the user you're still alive and awaiting an event.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
Hi All, I have a billing form as displayed below.I want to show products. I can use a combo box instead of product textbox. but since I have 100000 record of products, combo box is not a good option. Instead, As the cursor enter the product text box, I want to display another form with textbox and datagrid view exactly in the place of product text box.(it looks like a combobox for the user). The user can then search and select a record from the form and the selected value is returned to the product text box, after closing the search form. Iam having the below issue
1. Iam not able to correctly position the search form in place of product text box. can anyone help please. below is the code
Private Sub TextBox1_Enter(sender As Object, e As EventArgs) Handles TextBox1.Enter
frml.Location = New Point((Me.Location.X - TextBox1.Location.X), (Me.Location.Y - TextBox1.Location.Y))
frml.Location = New Point((My.Computer.Screen.Bounds.Height - Me.Height), (My.Computer.Screen.Bounds.Width - Me.Width))
frml.Show()
frml.Visible = True
End Sub
How to display a search and select form in place of a text box in c# or VB.net. The search form should look like a dropdown box to the user
|
|
|
|
|
You could do this with just a TextBox and a DataGridView . As the details are added to the TextBox you select a set of records from the database and use them to populate the DataGridView .
|
|
|
|
|
Hello in my Windows forms application wich show database records, I have a button to save new records but new records are stay only in obviously between form and database, and dont save to a database. Here is a code. I using a Dataset, and Dataadapter
Thanks a lot !
I have this from http://www.homeandlearn.co.uk/csharp/csharp_s12p9.html[^]
private void btnSave_Click(object sender, EventArgs e)
{
DataRow row = ds.Tables[0].NewRow();
row[1] = txtFirstName.Text;
row[2] = txtSurname.Text;
row[3] = txtJobTitle.Text;
row[4] = txtDepartment.Text;
ds.Tables[0].Rows.Add(row);
try
{
objConnect.UpdateDatabase(ds);
MaxRows = MaxRows + 1;
inc = MaxRows - 1;
MessageBox.Show("Database updated");
}
catch (Exception err)
{
MessageBox.Show(err.Message);
}
btnCancel.Enabled = false;
btnSave.Enabled = false;
btnAddNew.Enabled = true;
}
|
|
|
|
|
Where is the code for your UpdateDatabase method?
|
|
|
|
|
There is code for UpdateDatabase
public void UpdateDatabase(System.Data.DataSet ds)
{
System.Data.SqlClient.SqlCommandBuilder cb = new System.Data.SqlClient.SqlCommandBuilder(da_1);
cb.DataAdapter.Update(ds.Tables[0]);
}
|
|
|
|
|
Are you sure that the DataAdapter is correctly linked to the DataSet ?
|
|
|
|
|
I think that Dataset is correctly connected to a Dataadapter , because in form I see data from database. What would happen when a Dataadapter is incorrectly connected to a DataSet ?
|
|
|
|
|
If they are not properly linked then the updates will most likely fail, although I would expect to see an exception in such a case. It is difficult to be certain what the issue is, although you may like to try contacting the person who provided the sample code.
|
|
|
|
|
Put a breakpoint on
cb.DataAdapter.Update(ds.Tables[0]);
then select "ds.Tables[0]" and right-click. Choose quick watch. In here you can drill down on the object. Check if the change you made is there. if not, my guess is that you'll need to set some property in the designer or when creating the Dataset/DataAdapter in code.
Hope this helps.
|
|
|
|
|
From the last paragraph of said tutorial;
(If the new record doesn't appear when you restart, go back to Design Time. In the Solution Explorer, click on your Database under Resources to select it. Now have a look at the Properties window below the Solution Explorer. Locate a property called Copy to Output Directory. It has three settings: Do not copy, Copy always, and Copy if newer. If your database is not updating, try either Copy if newer or Copy always.)
I did not see any update-statements, nor an implementation of "objConnect.UpdateDatabase(ds)". I suggest you look for a different tutorial. For one, I think that databinding is better explained on MSDN[^], second because databinding hides a lot of the (boring) details.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|