Search the Community
Showing results for tags 'vb.net'.
-
I'm trying to build a sort of Plex media server knock off for a class project. I don't intend to copy any of the big features of plex like matching media data or having its own built in media player. I just want to build a server application that hosts a database list and a bunch of media files and a client application that will connect to the server, display the hosted database file and update a picture box whenever a data grid view selection is changed. Attached is some of the code I wrote along with a screenshot of the project to get an idea of what I want to do over the network. Public Class Movies Dim videoString As String 'tv shows connection String: Provider=Microsoft.ACE.OLEDB.12.0;Data Source="|DataDirectory|\TV Shows database.accdb" 'movies connection String: Provider=Microsoft.ACE.OLEDB.12.0;Data Source="|DataDirectory|\Movies Database.accdb" Private Sub btnEdit_Click(sender As Object, e As EventArgs) Handles btnEdit.Click EditMovies.Show() End Sub Private Sub btnBack_Click(sender As Object, e As EventArgs) Handles btnBack.Click Me.Hide() WelcomePage.Show() End Sub Public Sub Movies_Load(sender As Object, e As EventArgs) Handles MyBase.Load 'TODO: This line of code loads data into the 'Movies_DatabaseDataSet2.Movies' table. You can move, or remove it, as needed. Me.MoviesTableAdapter2.Fill(Me.Movies_DatabaseDataSet2.Movies) End Sub Private Sub DataGridView1_SelectionChanged(sender As Object, e As EventArgs) Handles DataGridView1.SelectionChanged Dim posterString As String = DataGridView1.Item("Poster", DataGridView1.CurrentRow.Index).Value.ToString '"Poster" refers to the dataGridView column PictureBox1.Image = Image.FromFile(posterString) videoString = DataGridView1.Item("Location", DataGridView1.CurrentRow.Index).Value.ToString End Sub Private Sub btnPlay_Click(sender As Object, e As EventArgs) Handles btnPlay.Click Process.Start(videoString) End Sub End Class
-
I'm looking to create a basic algorithm that allocates jobs to workers based on skill level and workload. however, I'm stumped at where to start. Background Mobile phone repair store Worker qualifications stored in text files Algorithm is run as button click on the Add Repair Form (VB.net) Requirements Algorithm Reads worker files sequentially, noting the current workload value, finds the worker with at least amount of work checks if he is qualified to do the task If yes assigns job, If no, checks the next worker if 2 workers have the same amount of current jobs reads the first (sorted alphabetically) and runs checks im struggling to even get psuedocode out for this. All Help appreciated (Not asking for a full creation, just how to make this possible, pseudocode wise) Basic attempt at flow chat may help
- 11 replies
-
- job
- allocation
-
(and 3 more)
Tagged with:
-
Hello all, I am very new to this so forgive my ignorance, I have two dictionaries in Vb.net, and I need to cross reference them and come up with a total sum. For example. User1, £5.00 User2, £10.00 User3, £2.50 User4, £7.60 User5, £11.00 User1, Dept1 User2, Dept2 User3, Dept1 User4, Dept3 User5, Dept2 The end result I am looking for is... Dept1, £7.50 Dept2, £21.00 Dept3, £7.60 I am pulling the information from two different databases, Active Directory for "user and dept" and a SQL database for "user and cost." I have tried arrays and dictionaries but I've never used either so am probably doing it wrong. What would be the easiest way to cross reference two dictionaries when I do not know before the program runs how many "users" it is going to pull but the first dictionary is about 15,000 results and the second is about 5,000. Thanks
-
So basically after days of researching i finally found a way to detect if my player(green square) is intersecting with another picturebox. but my code makes it so that i have to write down which picturebox it is thats intersecting. Private Function IntersectWith() As Boolean Dim recInter As Rectangle recInter.Location = MyPlayer.PointToScreen(New Point(0D, 0D)) recInter.Size = New Size(MyPlayer.Width, MyPlayer.Height) Dim ChkPass As Rectangle ChkPass.Location = Floor2.PointToScreen(New Point(0D, 0D)) ChkPass.Size = New Size(Floor2.Width, Floor2.Height) Dim doesIntersect As Boolean = recInter.IntersectsWith(ChkPass) Return doesIntersect End Function example.. Picturebox1 is player.. Picturebox2 is Mayor. Picturebox3 is Bandit. can i ask is there a better way to find out which picturebox it is that my player is intersecting so that i can run it into a function? or if you have a better way to implement intersection/collision could you please share it?
- 2 replies
-
- vb.net
- programming
-
(and 1 more)
Tagged with:
-
Good Afternoon Everyone... Trying to do something that should be stupidly simple but I just can not figure it out. I want an XML file for two lists so the name of a TV Show and an ID number. I can create an XML file no problem and it'll look something like: <?xml version="1.0" encoding="UTF-8"?> -<TVShowsN> <TVShows ID="123456" Name="The Vampire Diaries"/> <TVShows ID="987654" Name="Arrow"/> </TVShowsN> And I can happily add as many as I like.. which is great. I can load that file so that ListBox1 index 0 shows the name and Listbox2 index 0 shows the ID. Index 1 shows the next show and ID etc.... The problem is I want to be able to add more and save them at runtime. So I have another two text boxes to add a new name to listbox1 and a new ID to listbox2.... the problem is saving both listboxes to the XML file... I just can not get it to save it keeps crashing at different sections depending how I try to resolve it. If anyone knows how to save two listboxes to a single XML file that would be great. Thanks
-
Hey guys! I was hoping someone might be able to give me a hand. A friend of my father's has a small business and he wants a way to manage the inventory. I've developed an application on VB.Net that accesses a local XML database (which, I know, is probably not the best solution performance-wise), and I'm in the process of optimising it. During this process, the client said he would like to access the inventory remotely, so as to be able to sell off-site, perhaps during business trips. Anyway, bearing in mind that the application hasn't been deployed yet, therefore no real data has been written to the database: do you think it'd be a good idea, if at all possible, to build a server and have it store the DB there? Maybe using SQL? I am definitely not a pro, so if anyone could point me in the right direction, I'd be very grateful. P.S., I've tried using a MS Access DB on my app, thinking I would gain performance, but I simply couldn't get it to work.
-
Hello, I would like to run a .exe winform program that is interactive before any user can login in windows 10. I have already tried a few things, like running it as a scheduled task or as a startup script, but if I do it like this, the program always runs in the background and I can't see/use the GUI. Thanks in advance!
-
I made a thread on StackOverflow, however the majority of people on there are dicks. So, I am making an "overlay" of a sort. Long story short I need an image on top of everything (which I got). But I am trying to get it so it presses behind the image and does not focus the vb.net application. I can do it with only one color however (the white background color) with a transparency key so everything white is transparent. (however my image is not). I tried to create a graphic but had no luck. Has anyone else been able to do this? - Thanks
- 3 replies
-
- clickthrough
- vb.net
-
(and 2 more)
Tagged with:
-
Hey I am new to VB.NET, I played around with VB6 almost 10 years ago and am just trying to learn again. I am trying to make a basic program and I need to save a settings file. Name, Department, Account Number, Reference Number. I only need one account and reference number but multiple names and departments. I was trying to do it with an INI file and was told that an XML file would be easier and give me more room to expand if need be as it has a lot more options. A basic example of the settings file would be; [Users] John Smith=Department 1 Jane Smith= Department 2 Alex Smith=Department 1 Oliva Smith=Departmnet 3 [Accounts] AccountNumber=123456 ReferenceNumber=987654 and it to save it into some sort of file so that the program would be able to read and save the data. I need to be able to add and delete users from the program. Thanks
-
Greetings Iam trying to make a Picture / Photo Viewer in WPF with Visual Basic and now iam on a Point where i Need YOUR HELP ! My Programm Looks like this : TextBox = the path of the Picture / Photo Folder Btn_Load = loads the Files from the Path into a Listbox Btn_Show = *thats the Problem* how can i make the Photos visible ? Dim Number as Integer = Listbox.items.count , gives back the amount of Pictures in the Folder now is it possible to create those Images automatic with a button ? like so : Dim Images(Number) = Image ? and then with the Child command put them in a scrollviewer or something like that ?. hopefully someone can help me.
-
Hi all first time posting in this section of the form. So I'm making this program in visual studio 2013 in VB.NET Lets say I have 2 forms: Form1 and Form2 and on Form1 I have DataGridView1 and on form 2 I have DataGridView2 Both data grids have the same columns. How can I on the click event of a button on Form1 Get all the data from DataGridView1 from the row i'm currently focused/selected on to be transferred into DataGridView2 on Form2 ??? Image of what i'm trying to do. If anyone can help me out with this one it would be much appreciated. Thanks
-
Hi! So I want to use the streamwriter and reader without using the savefiledialog and openfiledialog. Basically what I have is a texteditor that is suppose to save a file without the user having to do anything(therefore I don't want the filedialogs). But basically there will be a timer running every 5 seconds and if there is a change in the textbox then it will write this change to a file that I will put in "C:\Program Files\Notes\autosave\FILENAME.txt" (FILENAME.txt will be the current date and time...) Then I want to be able to, if the program suddenly crashes or the user accidently shuts the program or computer off, turn the program on and then load the autosave. (With streamreader, without the openfiledialog) So, the program is based around being able to restart and then just start the program again and you have your info you typed up before the reboot still there without a manual save. But I cannot remember how the streamwriter and reader works... Remember that it's VB.NET, the language that requires the user to have net framwork. So no C# codes because the rest of the program is already done and I don't feel like redoing it all for C#... Thanks! Regards, Ludwig Johnson
- 6 replies
-
- streamreader
- streamwriter
-
(and 6 more)
Tagged with:
-
ProjectZ Notes I saw a few XNA and C# threads in this section, hope it fits here. I'm new to the forums, but have been watching Linus for X years now. This is my first post so I just thought I'd share some of my work Common Questions What is Project Z? Project Z is a Managed, fully extensible 2D UI framework. There are plans for making Project Z a full 2D Game Engine. Is Project Z Open Source? Yes. Check out the source on BitBucket! How Does Project Z work? Project Z uses the MonoGame framework which is a Cross-Platform implementation of the XNA framework. This means that everything is rendered either with the DirectX API for Windows, or OpenGL for Linux. Project Z Render Diagram How easy is it to start making my Application in Project Z? Take a look at some example source code and see for yourself! ''' <summary> ''' A Button Element Example ''' </summary> Dim Button As New UI.Input.Button(Me) With Button ' Set the button's Text .Text = "This is my test button." ' Set the button's Position .Position = New Vector2(100, 100) ' Allow the button to be moved by the user .isMovable = True ' Enable the button's premade animations .isAnimated = True ' Autosize the button to its text .AutoSize = True End With ' Finally, add it to the Scene. AddElement(Button) Can I make custom controls?Yes. Project Z is heavily geared to allow developers to re-use, modify, and create Element assets to truly make the application you want. ProjectZ Documentation In progress. Expect to see full documentation soon. UI Element Showcase Textbox Button Trackbar Polygon with Basic Fill & Point Cordinates for each Vector Polygon with Wireframe enabled to show Triangulation ProjectZ Requirements Development Requirements Visual Studio .NET Framework 4.0 XNA Framework MonoGame 3.2 DirectX End-User Runtimes Windows Phone Developer Tools Redistributable RequirementsDirectX End-User Runtimes - WINDOWS ONLYProjectZ Downloads & Useful LinksRemoved static links to binaries & source because they get updated so frequently. Please compile the source manually for the most up-to-date release. General LinksProject Z Source Project Z On Nuget XNA / MonoGame Tools & ResourcesXnaResources.com Content Tools
-
Hi! So basically I need help with figuring out a code that will be executed by a timer that has an interval of 7 minutes. What this code will do is simply something small that will not bother the user and not interupt things like powerpoint presentations or youtube videos etc. But it will just do something that makes sure that the computer does not start it's screensaver. The reason for this is that on my school the teachers computers has some sort of lock on them from the IT dep. that basically makes it impossible (that I know of) to change the time for when the screen saver will be activated and when the screen goes to sleep. So basically what I want this program to do is to every 7 minute or so execute a code that does something small and not noticeble so it will not bother anyone but we can have powerpoints on for longer than 10 minutes without the screen going to sleep. (Mostly you go through several slides so often it's not a problem but when you stop for us students to write notes or the teacher is talking about what is on the screen then there are problems... The IT dep. on the school are morons and refuses to remove it, or they just don't know why it is there and just will not admit it? But I thought I'd do this to make life easier for the teachers on my school. As well us students.) Im programming VB.Net not C# or C++ or C... I have thought about implementing a timer that will be for 1 hour that simply will stop the other timer that makes the computer "remove" the screensaver because it will eventually have to go into screensaver mode and if you forget the program on then the one picture may hurt your screen. So it can be good to have that there. I will then add a reload button to simply reload the timers for another hour. Please ask me for more info if you want it. But really, Im the one who has the questions! So I really appreciate if someone helps! Regards, Ludwig Johnson
- 12 replies
-
Hello, I'm making my own chat program (school project). I need some help. I can do the basic's client connecting to server, client sending message to server. server sending message to client. now the problem.. I want to send a message to a client on a specific ip address. I've looked but don't find an answer anywhere. can someone help me? sorry for my bad English. thanks in advance