Jump to content
Xtreme .Net Talk

daveydave400

Members
  • Posts

    20
  • Joined

  • Last visited

Everything posted by daveydave400

  1. Well I have access to it, because I can go through task manager and turn it off that way but I would rather have the program do it for me, but if what you meant by I don't have access to it was that I can't get to it from the program code then Thanks Anyway.
  2. Ok I was wondering if it was possible, which I'm sure it is, to end a process of a program at my school that stops me from using firefox. The process is called "navagent.exe". So I have a start up program and when I click the button to end the program I want it to be able to open firefox, which it can but then it closes because of the blocker but before it can run I need to end the process and I would rather not go through the task manager and do all of that. If there is a tutorial or something that someone knows of that would be great. Thanks.
  3. Said before When you say populating I am guessing you mean how am I getting the values that are in the listbox into it. I stated in my first post that I am using an input box and each time the user enters a number and clicks ok on the inputbox it is added to the listbox. If you enter one digit numbers they are put in order because the sort property is set to true. ex: 1 2 3 4 when using 2 digit numbers: 1 15 2 3 34 5 If you meant some other meaning of populate please specify. Thanks.
  4. Ok, This is for a school assignment. All you need to know is that the user of the program enters values into an input box and then those values go into a listbox with its sorted property set to true. When you enter a 2 digit number it sorts by the first digit and not the second. Is there a way to sort the numbers by their value instead of just the first digit. For Example the listbox would show: 1 12 2 3 35 5
  5. Gotcha Well about the learning thing I am in class right now so I'm just waiting for that to come up. But about the imagelist thing yeah I tried that a little bit but I jsut thought it looked better. I put it to like the largest size you could and the 32 bit I think it was and it was a little off but I'm sure if I knew what I was doing it would have worked but I'm not trying to be a genious right now but yeah thanks everyone for the help.
  6. Thanks Anyway Well I'm sure that does work but I don't know how to use arrays and I dont have the patience to learn right now, not to sound disrespectful but I just used the Combobox3.selectedindex number as a reference as to what picture it uses. So like: If ComboBox2.SelectedItem = ("Baths Style A") Then PictureBox1.Image = Nothing ComboBox3.Items.Clear() ComboBox3.Text = ("Choose the Picture") Dim exedir As String = CurDir() Dim x, y As String x = 1 y = 0 For Each filename As String In Directory.GetFiles(exedir & "\BATHS & POWDER ROOMS", "BathA*.jpg") ComboBox3.Items.Insert(y, "Bath Style A " & x) x = x + 1 y = y + 1 Next End If It might not be as convenient and it doesnt work if the first picture or anypicture is deleted.
  7. Alright I have a program with a combobox thats items are based on how many files in a certain directory have a certain part of a name and extension. So basically it says: If ComboBox2.SelectedItem = ("Baths Style A") Then ComboBox3.Items.Clear() ComboBox3.Text = ("Choose the Picture") Dim exedir As String = CurDir() Dim x As String = 1 For Each filename As String In Directory.GetFiles(exedir & "\BATHS & POWDER ROOMS", "BathA*.jpg") ComboBox3.Items.Add("Bath Style A " & x) x = x + 1 Next End If So basically I was wondering if anyone could help me with maybe an example of how to give each item, the picture that it represents. So when you clicked on "Bath Style A 1" it would show the first picture it found in a picturebox. I am not using an imagelist because of the poor quality of the images. I would like to use the "System.Drawing.Bitmap.FromFile" command if possible. So if anyone could give me and example or tutorial on how to do this that would be great. I would rather not have someone give me the exact answer (I'm learning from my last post). Any help is greatly appreciated, Thanks.
  8. Alright Well I did all of that and I get most of it but where is it suppose to display the message or the text or w/e. Edit: Nevermind I found it Thanks I think I can figure it out or at least try to figure it out
  9. I don't know how the forum system works, sorry Whoa!, sorry man didn't mean to be disrespectful or anything I was just trying to tell you that I was editing my message cuz at the time it was the newest message and when I had thought it all over and figured out how I wanted to say everything you had already posted your thing before I finished editing mine, sorry I respect the help and I respect everyone that is giving it but yeah if you guys dont want to help anymore then please dont I can now see that I am basically asking you guys to finish my program for me and I am not trying to do that, it's just that I have tried to google a lot of the help and none of its close enough to what I need to understand what I need, but I am trying to learn a lot of things and most of them don't work and I am only a beginner and do not know how to do a lot of things in VB .net and obviously if i can't understand the code you guys try to help me with I need a few more classes but yeah I understand where your coming from didnt mean anything by it and you guys dont have to help anymore I'll just figure it out myself somehow. Edit: On your edit you told me to check out the msdn thing and I tried that but when I did it doesnt have "Directory" as anything it says that its not declared so maybe my version is different but yeah if anyone knows y or if that is the reason y please reply.
  10. Thanks Right before I read this again I found out the curdir thing on some website so instead of doing the whole application.startuppath I just declared a variable as the path: Dim exedir As String exedir = CurDir() If ComboBox3.SelectedItem = ("K1") Then PictureBox1.Image = System.Drawing.Bitmap.FromFile(exedir & "\IMG_0563F.jpg") End If Another Question: Does anyone know how on program load I can get the name of each folder in a directory or specifically the exedir, and then display each folders name as a line in a combobox and after doing that it takes every file in each folder that is a .jpg and for each .jpg file it creates a line in another combobox that is coded so for each file it would be like K1, K2, K3, etc. and if they picked another folder it would be something like B1, B2, B3, etc. and I'm sure I wont easily find this on the internet cuz i have been looking for quite a while.
  11. Right Well If you look at my last edited message you will see that I have basically solved the resolution problem and I need help on the whole directory thing. I dont know anything about try and throw commands what you just wrote I dont even understand, remember I am a beginner.
  12. A Little More Detailed My own solution: If I change the imagelist size of the images to 256, 192 which is the correct ratio i believe for 800 by 600 because the max size is 256, it makes the images much more visible, there is very slight blurr. So I changed the size in the imagelist removed and then added the images in the imagelist again and it was "basically" fixed. If anyone has a way using this same method to make the pictures even more acceptable please tell. My 2nd solution: Upon finding out my previous solution I found that if I add a image to the picturebox through the picturebox's image properties it has a lot better resolution so I will just make it load the images straight from the file instead of from the imagelist, Thanks anyway but I guess I solved it. If you guys know anyway to load images from the same file as the .exe file is located in I need help with that. This program is for a small cabinet business or something(got it through programming teacher), so he needs to put the program on a disc and distribute it to his customers or potential customers and autorun the program so then they choose a room, style, and look through the images for that style. I have all of that figured out but as many of you know not all disc drives have the same directory letter so is it possible to tell the program to get the images from the directory that it is in. Thanks.
  13. OK I have a program and all that really matters is that I am displaying a picture on a picturebox. When I display a 800 by 600 picture on a stretched picturebox it has horrible resolution it gets all pixelated and blurry and when it is displayed in normal mode it is like 5 pixels wide. Is there something I am forgetting or maybe I am doing wrong, if you have answers please tell. Thanks
  14. Thanks that works, I also found out that if you put DialogResult.Ok = 1 works but your way is better, more specific.
  15. Not totally understood Alright but you didnt totally understand what I said: http://members.fortunecity.com/daveydave400/Assets/programimage.jpg I want a user to be able to click on the "Run Other" button and a openfiledialog box opens they select anyfile and then after the click ok or open or w/e then they have to click the "Yes" button and it will open all checked programs and also the file that the user specified. So it might say something like: Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim OpenFileDailog1 As New OpenFileDialog End Sub Private Sub runother_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles runother.Click OpenFileDialog1.Filter = "Executable Files (*.exe) | *.exe | Word Documents (*.doc) | *.doc| All Files (*.*)| *.*" OpenFileDialog1.InitialDirectory = "C:\" OpenFileDialog1.ShowDialog() MsgBox(OpenFileDialog1.FileName) End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click If Yes1.Checked = True Then System.Diagnostics.Process.Start("C:\Program Files\LimeWire\Limewire.exe") If Yes2.Checked = True Then System.Diagnostics.Process.Start("C:\Program Files\MSN Messenger\msnmsgr.exe") If Yes3.Checked = True Then System.Diagnostics.Process.Start("C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE\devenv.exe") If OpenFileDialog1.ShowDialog = DialogResult.OK Then System.Diagnostics.Process.Start(OpenFileDialog1.FileName) If Yes4.Checked = True Then System.Diagnostics.Process.Start("C:\Program Files\Microsoft Office\Office10\WINWORD.exe") If Yes5.Checked = True Then System.Diagnostics.Process.Start("C:\Program Files\Internet Explorer\IEXPLORE.EXE") If Yes6.Checked = True Then System.Diagnostics.Process.Start("C:\Program Files\Windows Media Player\wmplayer.exe") End End Sub What you told me opens an openfiledialog box when i click "yes" as well as "Run other". Maybe now you can help me more directly. Thanks Anyway.
  16. Alright I want to make a simple start up program where I have a list of Names of Programs with check boxes next to them. I have it so if you click on the Yes button it uses if commands to open what ever program(s) were checked. The First Part - I want to add a button for OpenFileDialog so if a program is not listed, then a user can select the .exe file they want to run or a .doc file instead of just word, but I have it all worked out except for I can't open the file would anyone please tell me the code to open a file from an openfiledialog box, I know its simple but for some reason I am just missing something (It is more for other programs because otherwise I can just use "The Second Part"). The Second Part - For the Yes button I want to have it so if openfiledialog1.filename = anything with a filename(or later a filtered extension) then open that filename but I cant get it to let me put *.* or *.doc. So my question is what do I put If OpenFileDialog1.FileName = (*.*) Then System.Diagnostics.Process.Start(OpenFileDialog1.FileName) How do I go about this? If anyone has any clue on how to fix my problem please help, much appreciated. Thanks P.S. If anyone knows any websites that are similar to ebypass.org for getting past school district filters on websites please list some, I think my school is filtering ebypass.org now or something cuz it doesnt work there but it does at home.
  17. hey i figured that you just have to run it from a local drive instead of the server drive that they give us from novell but thanks anyway. And if anybody knows a site that bypass's schools blockers for websites feel free to share. Ebypass.org used to work but now it says that their account is not payed for or something so anyinformation would be great.
  18. Alright working in a programming class at my high school and any end commands or openfiledialog boxes or anything like that do not work they get an error message about systemsecurity. Options to break continue or help or something so if anybody is still in high school we need help.
  19. Sweet thanks man that works, maybe my teacher will give me extra credit. P.S. Sonic Rules (Sega Genesis Games)
  20. Alright I am making a constitution day program thing for school and I need to make multiple lines of the text that I am putting in a messagebox.show command. Does anyone know an easy way to do this or a way to do it at all, my teacher doesnt even know how. So any help would be appreciated! :D
×
×
  • Create New...