Question: Use either sizers or absolute positioning; your choice. Your layout does not need to look exactly like mine, but it does need the same widgets
Use either sizers or absolute positioning; your choice. Your layout does not need to look exactly like mine, but it does need the same widgets and they need to be visible when the window opens. the values are dollars, so round any calculations to no more than decimal places so there are no numbers that look like you need a loop to send the stock requests one at a time. In order to have a loop send your requests to finnhub, you will need an API key. if you don't want me to see your api key, you can type wxyz in for the access token before sending me your code, but leave the rest of the code intact so I only have to substitute my key in place of yours. Hang onto your access key. to make this work your code will have to query the database and retrieve the company, symbol, purchase price, and number of shares in order to display this data along with the finnhub values. Do not hard code the dowstocks information in your program. Start early. As usual, there is an example in the lecture notes that should give you a good start. Let me know if there are questions. BIG Hint: You need a loop, a loop that reads a line of data in from the database, then makes a request to the web service for the current price of that stock, uses that stock price to calculate profit and loss, then puts everything in the list control for that row. There are other things to do as well. Here's kind of an outline. #connecte to stocks db fetch the rows of data #loop thru each row of the stocks table. # get the stock symbol for the stock in this row # concatenate the request to the web service for that stock # get the current price for the stock from the request # calculate profit or loss # append info to the list control For a loose generalization,
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
