|
I don't know of a way to make an arrow key into a hot key, other than overriding one of the key events. There may be a way, I just don't know.
As far as why the underline appears or not, in the later versions the underline on menus, buttons, etc. only appears after one presses the Alt key. For better or worse, that's the way the system works. (Personally I liked the underline always showing up, but it's not a big deal.)
CQ de W5ALT
Walt Fair, Jr., P. E.
Comport Computing
Specializing in Technical Engineering Software
|
|
|
|
|
Collin Jasnoch wrote: Any idea why this is?
Press Alt? (left Alt)
|
|
|
|
|
Isn't that configurable in Windows?
Display properties | Appearance | Effects | Hide underline blah blah blah
I always clear the checkbox.
[Edit] This is for Win XP, and perhaps earlier.
|
|
|
|
|
Thanks PIEBALD, I just learned something.
"If you're using Windows Vista, go to the Vista Control Panel - Appearance & Personalization - Ease of Access Center - Make the Keyboard Easier to Use. Check the box by "Underline keyboard Shortcuts & access keys". "
CQ de W5ALT
Walt Fair, Jr., P. E.
Comport Computing
Specializing in Technical Engineering Software
|
|
|
|
|
::smack forehead:: Oh, right, my instructions were for a worthwhile version of Windows.
|
|
|
|
|
Hi Have a good day ....
I am bulding a webbrowser by C# ....
and I want to add this features to it ....
Is There is any peice of code , any library or any advice ,
that I can tell the ( Total Upload , Download of Internet Traffic for my application )
Thank in advance
I know nothing , I know nothing ...
|
|
|
|
|
Since you don't say how you are retreiving web pages, it's pretty much impossible to tell you how to do this.
|
|
|
|
|
Couldn't you just add something to a "global" variable every time something is downloaded/uploaded?
|
|
|
|
|
I am using C# WebBroswer Control ...
I know nothing , I know nothing ...
|
|
|
|
|
Stark DaFixzer wrote: I am using C# WebBroswer Control
is slightly different from "I am bulding a webbrowser"
You could try and use the WebBrowser.Navigating event to perform a little WebClient or HttpRequest action getting the size of the page (just ask for the HEAD, it should contain length information) before the WebBrowser loads it.
Alternatively you could hook up the DocumentCompleted event and hope to get the length from the DocumentText property, but I am not sure that would always be correct, and if so, efficient.
For uploads, I don't know.
Luc Pattyn [Forum Guidelines] [My Articles]
DISCLAIMER: this message may have been modified by others; it may no longer reflect what I intended, and may contain bad advice; use at your own risk and with extreme care.
|
|
|
|
|
Counter-acted the B.S. 1 that you got...
|
|
|
|
|
Maybe "I did/didnot create a browser" didn't go down well.
Luc Pattyn [Forum Guidelines] [My Articles]
DISCLAIMER: this message may have been modified by others; it may no longer reflect what I intended, and may contain bad advice; use at your own risk and with extreme care.
|
|
|
|
|
That's just IE embedded in a control. I have no idea how to steal such statistics from it - if IE even has them then it has* to be possible somehow but maybe you'd need nasty hacks.
* yes it would have to be possible, if the information is somewhere in RAM and someone (IE in this case) knows where it is, then you can get it
|
|
|
|
|
As far as downloading html, you can access the browser control's DocumentText and get the size there. If you're downloading files, graphics, etc., I think you'll need to handle and count those sizes manually.
As for uploading, well, since you'll be controlling what to upload, just get the size when you upload it.
Or did I miss something?
CQ de W5ALT
Walt Fair, Jr., P. E.
Comport Computing
Specializing in Technical Engineering Software
|
|
|
|
|
What if you use an upload thing that is present on some sites? IE would upload the file then right?
|
|
|
|
|
Probably so. But if IE is handling things directly, then there's no real way that I know of to figure the sizes. As you pointed out earlier, IE might have the statistics -- if there's a way to get to them.
I don't know a general way to do what he wants. I'll be interested in seeing if someone else has a solution, though.
CQ de W5ALT
Walt Fair, Jr., P. E.
Comport Computing
Specializing in Technical Engineering Software
|
|
|
|
|
Since you're not actually building a brwoser control, but wrapping the one in the toolbox in your own UI, there's no real method to get the data you want. The browser doesn't expose this information and using alternate methods would only result in partial results at best.
If you want those stats, you're going to have to build and make the requests yourself and handle the returned page as well. That's about the only method you've got to knowing how much data was sent and received.
|
|
|
|
|
Thank you all for your help ....
your time is very much appreciated.
I know nothing , I know nothing ...
|
|
|
|
|
Guys i have a text file that i store my settings in so that they are availible in every forum .
basicly its in the following format
DownloadFolder = /mnt/md1/public/Downloads/
TelnetUser = root
TelnetPassword = something
TelnetIP = 192.168.2.2
So im looking for a way to take each of those settings and turn them into strings with values inside my c# program . Im useing the stream reader class below but im not sure what to do next after i split the strings into an array .
private void LoadSettings()<br />
{<br />
StreamReader Settings = new StreamReader("Settings.txt");<br />
string line;<br />
while ((line = Settings.ReadLine()) != null)<br />
{<br />
if (line.StartsWith("/"))<br />
{<br />
}<br />
else<br />
{<br />
string[] splitArray = line.Split(new char[] { '=' });<br />
<br />
<br />
}<br />
}
|
|
|
|
|
Member 6038196 wrote: but im not sure what to do next after i split the strings into an array .
How are we supposed to know? All you said you wanted to do was:
Member 6038196 wrote: im looking for a way to take each of those settings and turn them into strings with values inside my c# program .
Which you might already have with splitArray if your code is correct. From there, you can do whatever you want next but we have no idea what that is.
|
|
|
|
|
Hi,
if the non-comment lines are all "key=value" statements, AND assuming all keys are different, you could store them all in a Dictionary<string,string> making retrieval easy.
Note: Dictionaries don't preserve order, so if you were to modify and store the settings again, the file might look different (and your comments would be gone). If you want to keep comments and order, you could define your own little "MySettingItem" class to keep comment, key and value, and just build a List<MySettingItem> while reading the file.
Luc Pattyn [Forum Guidelines] [My Articles]
DISCLAIMER: this message may have been modified by others; it may no longer reflect what I intended, and may contain bad advice; use at your own risk and with extreme care.
|
|
|
|
|
Not sure if I understand correctly, but is it something as simple as:
string key = string.Empty;
string val = string.Empty;
if (splitArray.Count > 1)
{
key=splitArray[0];
val=splitArray[1];
}
at this point, you've got both elements of your configuration item that you can then do whatever you want with. HTH.
Josh
Find a penny, pick it up, and all day long you'll have a back-ache...
|
|
|
|
|
I prefer to use XML and then use a System.Xml.XmlDocument to read and write it.
|
|
|
|
|
I want the data stored in database to be displayed from the first record in the database. These data were submited to the database via textbox and I want to load the first record from database and display in the textbox.
below are the codes that I have check Beginners guide to accessing SQL Server through C# but can't still do it. No error but dont know what to do. Please I need help on this
Thanks
Ademola.
private void COMPANY_INFO_Load(object sender, EventArgs e)
{
SqlConnection myConnection = new SqlConnection("user id=sa;" +
"password=admin123;server=ADEMOLAPC;" +
"Trusted_Connection=yes;" +
"database=Kay_Nylon_Db; " +
"connection timeout=30");
myConnection.Open();
//try
//{
SqlDataReader myReader = null;
SqlCommand myCommand = new SqlCommand("select * from Company_Info", myConnection);
myReader = myCommand.ExecuteReader();
while (myReader.Read())
{
Console.WriteLine(myReader["Company_Id"].ToString());
Console.WriteLine(myReader["Company_Name"].ToString());
Console.WriteLine(myReader["Company_Address_Line1"].ToString());
Console.WriteLine(myReader["Company_Address_Line2"].ToString());
Console.WriteLine(myReader["Fax"].ToString());
Console.WriteLine(myReader["Email"].ToString());
}
|
|
|
|
|
Your connection string is wrong to start with. If you supplied a username and password you do not use TrustedConnection.
The rest of the code looks reasonable, so long as the SQL statement is correct and there's data in the Company_Info table, and the column names are correct.
|
|
|
|