Click here to Skip to main content
15,067,832 members

Comments by GKP1992 (Top 142 by date)

GKP1992 19-Dec-19 3:55am View
   
Deleted
Quote:an anybody give reason and solution in simple form.
No.
Most probably you're missing a using directly.. something like System.Collections, but I'm not really sure.
GKP1992 27-Nov-19 23:28pm View
   
Stop using it like that?
GKP1992 1-Nov-19 4:53am View
   
I like how you gave them the solution but still left some things for them to figure out.
+5
GKP1992 1-Nov-19 4:53am View
   
Deleted
I like how you gave them the solution but still left some things for them to figure out.
GKP1992 31-Oct-19 5:53am View
   
Run the test, if it passes it is correct otherwise it's not.
GKP1992 31-Oct-19 5:52am View
   
Looks like an interview assignment to me.
GKP1992 17-Apr-19 3:56am View
   
This may be of some help.
[^]

Also, nvarchar uses 2 bytes per character whereas varchar uses 1. The direct correlation of success at 368 and failure at 767 is suggestive enough of that.
GKP1992 22-Feb-19 7:00am View
   
And what does the data in the error function say? Try to debug a little. Probably it has "404 not found" error.
GKP1992 22-Feb-19 0:17am View
   
What HTTP response do you get in the browser?
GKP1992 15-Jan-19 22:44pm View
   
Try calling the incrementer function on the button click.
GKP1992 17-Oct-18 8:16am View
   
There are numerous tools on the internet that do it for you. Try to google search for once.
GKP1992 5-Sep-18 1:30am View
   
Let college take its course. Learn well what is being taught, and you'll have a good enough idea of computer programming by the end of it. Programming cannot be learnt overnight. There's no easy (faster) way, so get ready to dive in.
GKP1992 17-Aug-18 10:10am View
   
I have actually tried that as well, the only difference is the unexplained call to selection changed method when using mouse mode.
GKP1992 26-Jul-18 5:44am View
   
Try informing the police about it.
GKP1992 16-Jul-18 8:06am View
   
You should not stay where you are working right now. Leave asap.
GKP1992 6-Jul-18 4:21am View
   
Deleted
Sharing master pages is a bad idea, but if you're willing to go through the pain,
Dan Wahlin - Sharing Master Pages Across IIS Applications[^]
GKP1992 3-Jul-18 1:47am View
   
Looks interesting, I did something similar.
Thanks.
GKP1992 29-Jun-18 4:02am View
   
What is the error you get when trying to run it? By the looks of it, this code is already in C# so you don't need to convert it to C#.
GKP1992 22-Jun-18 2:36am View
   
Using the DateTime class, you can use the year property of the date and assign it to your variable.
GKP1992 20-Jun-18 0:06am View
   
Please do not add duplicate questions, close one of them.
GKP1992 8-Jun-18 3:15am View
   
The only issue is the first one "ORA-01403". Check why you have no data and fix that, there is a good chance that a "SELECT INTO" statement that has no data to select from is breaking your job. All other errors are a result of the first one.
GKP1992 28-May-18 23:45pm View
   
What do you mean by the count of the current number? Do you want to know how many hits there are in the matrix or just the number which follows the condition?
GKP1992 28-May-18 4:25am View
   
Did you try writing a.outerxml as it is in the VB code rather than a.OuterXML?
GKP1992 28-May-18 3:16am View
   
If I simply do this,
var x = "3V 1 TP&WB;-OV 29.95";
var y = x.Split(' ');

I get "3V", "1", "TP&WB;-OV" and "29.95" in y. So, you're doing something wrong.
GKP1992 24-May-18 3:38am View
   
Too subtle a hint I think. :D
GKP1992 22-May-18 7:39am View
   
wouldn't the .length crash if the $("#iframeID") is null?
GKP1992 22-May-18 7:37am View
   
What do you do when the browser does not have iframe?
GKP1992 22-May-18 2:54am View
   
:D
GKP1992 21-May-18 0:22am View
   
Why do you need to have such a long password anyway? Can a user ever remember that?
GKP1992 18-May-18 7:39am View
   
Just me or the password string goes on and on in a single line overflowing the CP page?Chrome by the way.
GKP1992 14-May-18 0:06am View
   
Can you post the actual exercise statement? Your statement is quite hard to understand.
GKP1992 11-May-18 8:09am View
   
What is the problem with the one you came up with? The only thing I see is that your regex can accept "None" irrespective of the case of the letters. If you want only "NONE" specify it literally.
GKP1992 11-May-18 4:12am View
   
Did the same. :)
GKP1992 11-May-18 3:51am View
   
I presume it is SQL server since they do not want to install it.
GKP1992 11-May-18 0:01am View
   
As Christian Graus pointed out, rather than checking whether HashInfo contains HashDecoded, check whether HashInfo equals HashDecoded.
GKP1992 9-May-18 1:45am View
   
Deleted
You can debug and find out what value is passed in the parameter @id. Look at the dataGridView1.Rows[i].Cells[0].Value.
GKP1992 7-May-18 6:38am View
   
TY.
GKP1992 4-May-18 6:12am View
   
Good man Steve.
GKP1992 4-May-18 5:38am View
   
Try casting Project to object type and before assigning to the param value.
Better yet, try this
param[8].Value = (object)(Project ?? DBNull.Value);
GKP1992 4-May-18 5:12am View
   
Do not post the same question more than once. This annoys people who are otherwise willing to help.
GKP1992 4-May-18 4:21am View
   
Try using the XML generated by your code to call the service from SOAP UI. Maybe your code does not create the XML you want.
GKP1992 4-May-18 2:11am View
   
Why did you decide to use exceptions to achieve this?
GKP1992 4-May-18 2:03am View
   
Thanks again.
GKP1992 4-May-18 1:59am View
   
Thanks. :)
GKP1992 4-May-18 1:28am View
   
Check now.
GKP1992 1-May-18 23:49pm View
   
Please mention precisely, what issue you're facing with it. No one knows what you want your code to do and what it does instead.
GKP1992 25-Apr-18 7:45am View
   
Read the first paragraph of the solution. I removed those columns to avoid doing just that.
GKP1992 25-Apr-18 6:54am View
   
Okay, I was just too lazy to do that, also I changed the structure a bit to make the query cleaner. For example, I just added a foreign key relationship between the tables and removed the repeated columns.
GKP1992 24-Apr-18 23:35pm View
   
Usually, you add a reference to the DLL in your project. Then you can use it.
GKP1992 24-Apr-18 7:27am View
   
USE the log object and remove any objects you're not using.
GKP1992 23-Apr-18 4:53am View
   
Debug your web-service. You can use Postman to call the service without having to write code for it.
GKP1992 20-Apr-18 5:58am View
   
By "user device" I meant the device where the app is installed.
GKP1992 20-Apr-18 4:33am View
   
I guess he wants to access the SQLite database on a user's device after the app has been installed. Smells fishy to me.
GKP1992 13-Apr-18 7:50am View
   
Posting the same question twice will not get the result twice as fast. In fact, it will discourage people from helping you. Please close one of the questions.
GKP1992 12-Apr-18 1:45am View
   
Are you sure this is the correct body of the for loop? There isn't a proper condition.
GKP1992 12-Apr-18 1:43am View
   
Tried string Split()?
GKP1992 10-Apr-18 23:36pm View
   
A simple google search takes you to the MSDN page where you can find examples on both c# and vb.net. Visit here.
GKP1992 10-Apr-18 5:08am View
   
You need to do your homework yourself. Try it and then ask here what you do not understand or cannot seem to work out.
GKP1992 10-Apr-18 3:45am View
   
+5
GKP1992 10-Apr-18 2:06am View
   
Have you tried paying someone for this? I think you'll get a quicker resolution.
GKP1992 10-Apr-18 2:04am View
   
Please visit the Microsoft support for this.
GKP1992 10-Apr-18 1:50am View
   
Adding the same question twice does not get you the answer twice as fast. In fact the opposite, it drives away potential responders. Close one or the other.
GKP1992 10-Apr-18 0:40am View
   
Use web config connection string properties for that.
GKP1992 10-Apr-18 0:38am View
   
Take a look, it does exactly what you're looking for.
Visit here.
GKP1992 9-Apr-18 23:53pm View
   
Have you looked at model binding?
GKP1992 2-Apr-18 7:45am View
   
Check what is null. While debugging you will find the line on which the exception appears. Check if one of datagrid or datagrid.row are null.
GKP1992 2-Apr-18 3:48am View
   
Shouldn't this be datagrid.rows.add(drRow)?
GKP1992 7-Mar-18 3:23am View
   
What do you mean? Please use the improve question button to make your question more meaningful. Put information like what you're trying to do and what and where is the problem that you're facing.
GKP1992 7-Mar-18 3:19am View
   
Use Where instead of Select.
GKP1992 1-Feb-18 2:21am View
   
Yes, you'll need to call the constructor for each person as you are creating a new person each time. I misread that, apologies. Yes for PersonModel creating a constructor that sets the private members for each person in GetList. Add them to the result and notify the view about the change in the "list of persons" property to which the list is bound.
GKP1992 24-Jan-18 23:24pm View
   
Please use "improve question" button if you need to modify something. Do not create another question.
GKP1992 24-Jan-18 3:22am View
   
Did you try using the profiler?
GKP1992 14-Jan-18 23:30pm View
   
If you have so many records why don't you try server-side data grids and get new data when you change a page in the grid. I'm sure the page will load faster with fewer records to fetch.
GKP1992 2-Jan-18 4:54am View
   
There is no way SQL server can know which value to update out of the various values separated by commas. You have to do it programmatically and update the whole value.
e.g. Initial Value = ram, name
Logic to determine final value, takes initial value as input
Final value as output of previous logic.
use this value to update row.
update emp set emp_name = "final value" where empId = "id"
GKP1992 10-Nov-17 6:00am View
   
You'll have to create it from scratch. Although you can use the browser's developer tools to some extent, most of the work you have to do yourself.
GKP1992 8-Nov-17 5:28am View
   
How does it fail? Does it insert wrong values in DB or doesn't convert at all?
GKP1992 7-Nov-17 23:03pm View
   
You need to start reading really.
Start with this https://www.amazon.com/C-Primer-Stanley-B-Lippman/dp/0321714113.
GKP1992 7-Nov-17 22:58pm View
   
It's not really easy to explain what you have to do. Once you start doing it you'll get to know. The idea is to keep common functionalities in a single file just like for wind and temparature. I would've added another class for Weather station that holds the information about the weather station, and then a class that uses all these to measure and display the weather information. Call these functionalities from the main function. I get that it may sound confusing, so the only way is to dive in.
GKP1992 7-Nov-17 22:27pm View
   
I get that, I used it just for the sake of using a better-known term, figured that they'll get to know when they read about it.
GKP1992 7-Nov-17 22:27pm View
   
Deleted
I get that, I used it just for the sake of using a better-known term, figured that they'll get to know when they read about it.
GKP1992 7-Nov-17 5:41am View
   
Thanks :)
GKP1992 6-Nov-17 23:16pm View
   
Why are you using the Timer.Tick event, and not the mouse click event?
GKP1992 6-Nov-17 22:42pm View
   
If you're trying to make a game even as a learning project. Why not use a game engine (I hear unity is pretty good). I will save you a lot of time and headache.
GKP1992 6-Nov-17 22:40pm View
   
As PIEBALDconsult pointed out, storing dates as strings in the database is a horrible idea. I can think of only one reason why someone would have done so, is to be able to use the like clause etc, but even then it does have any advantages. It just slows down your DB server. Please use DateTime.
GKP1992 6-Nov-17 22:31pm View
   
There is numerous websites/forum providing that kind of support for example XDA-developers forum. A simple google search will direct you there. Please use your time well.
GKP1992 3-Nov-17 7:19am View
   
I think it is called a block in Oracle. Goes like this

declare {var_name} {vartype} := {value};
begin
{write query that uses var here.}
end
GKP1992 2-Nov-17 2:31am View
   
As far as I understand, you insert the query into a table with query id as the primary key. Is that correct? Also, which version of Oracle are you using?
GKP1992 1-Nov-17 23:56pm View
   
If you have a problem in the PasswordSignInAsync method, it is a good idea to check inside that method, see where the problem occurs and post the "problematic code" here. We cannot see your computer to tell what is happening. OTOH, if the method is inside a third-party API then there should be some information about its behavior in the documentation.
GKP1992 1-Nov-17 23:51pm View
   
If you want to know if the checkbox is checked or not, why not use the Checked property?
GKP1992 24-Oct-17 0:18am View
   
That usually happens when I change the dot net framework, the designer files get corrupted and I cannot see anything on the designer. Is this the case?
GKP1992 23-Oct-17 7:49am View
   
LOL.
GKP1992 23-Oct-17 7:09am View
   
Running the application from the exe should not have this issue. It is strange that you have it.
GKP1992 23-Oct-17 5:12am View
   
It would be better to let everyone know what worked for you, since you have accepted every answer. :D
GKP1992 23-Oct-17 1:31am View
   
Are you using the IDE or the .exe to run the application?
GKP1992 18-Oct-17 2:43am View
   
Probably because you have the information of only one user in the action result method.
Do you think using a collection of user info to iterate through to assign them the random number and then saving/updating will do the trick?
GKP1992 17-Oct-17 7:01am View
   
Just tested my solution with trailing zeroes, it works :-D, even though I did not intend it to.
GKP1992 17-Oct-17 6:55am View
   
I think trimming will give a wrong result if I use my solution, 0.60 - 0.01 = 0.50, whereas 0.6 - 0.1 = 0.5. My vote of 5.
GKP1992 17-Oct-17 4:44am View
   
I was considering the point you make in step 3.2, but I did not go with it since a fraction with a 0 in the end, did not make sense. Since it is a user entered string, it doesn't have to.
GKP1992 17-Oct-17 2:22am View
   
Have you considered using sessions instead of variables?
GKP1992 16-Oct-17 23:33pm View
   
Yeah, I missed that you wanted to upload multiple files. In that case, the regex is not useful to you.
Also, you need to ask yourself a few questions like if you're selecting multiple files and some of them are not valid, what should happen? Should the validator accept the only valid files or should it discard all of them?
I will update the anwser.
GKP1992 16-Oct-17 7:17am View
   
OP wants to update all records, if you just remove the where condition, your solution would be perfect.
GKP1992 16-Oct-17 7:08am View
   
Have you considered using async and await?
GKP1992 16-Oct-17 2:46am View
   
Please do not copy and paste a chunk of code and expect people to go through it to find the problem for you. You can use the "IMPROVE QUESTION" button to update the question with more relevant information.
GKP1992 13-Oct-17 6:06am View
   
If you know the connecion string, you know the DB provider. You can make query based on that information.
GKP1992 11-Oct-17 14:49pm View
   
If you have a problem with the answer or some suggestions, please leave a comment along with your downvote. Let's help each other grow.
GKP1992 9-Oct-17 23:44pm View
   
Sorry, but you're in the wrong place with the wrong intention.
GKP1992 9-Oct-17 7:24am View
   
Please debug your code and find out which line throws the error.
GKP1992 9-Oct-17 2:02am View
   
From what I understand from your question, you want to update your master records with the sum of the Unit prices in the details records based on the MasterId. Is that what you want to ask?
GKP1992 6-Oct-17 8:08am View
   
Strange.
GKP1992 6-Oct-17 8:06am View
   
Yes, and we only check the final value.
GKP1992 6-Oct-17 7:21am View
   
When is it working, And how are you trying to save the image? Please share the specific code which you think has the bug.
Thanks.
GKP1992 6-Oct-17 7:17am View
   
do not see the necessity of the new variable, also to compare with 26 we have to write index <= alphabet.lenght in the for loop condition which we cannot do because alphabet[26] will break for the last comparison. Since it is index < alphabet.lenght, maximum possible value for occurencePositive is 25 (if all the letters are found). Anyways, glad it helped.
GKP1992 6-Oct-17 5:47am View
   
"easily do the comparison"? this is a task of big teams. Groups like Amazon and Walmart do this. It is anything but easy.
GKP1992 6-Oct-17 0:29am View
   
No one will help you finish your homework, but here are some hints. There are two Getpercentage methods with the same signature, this is confusing for the compiler. The methods Getpercentage, gettotalnostudents and Getpercentage do not know what are a,b,c,totalnostudents, s and t. Start with defining those variables and take it from there.
GKP1992 5-Oct-17 23:52pm View
   
No problem. :-)
GKP1992 5-Oct-17 8:23am View
   
You can use reflection to enumerate the properties of your entity. That way you can easily identify which properties to update.
GKP1992 5-Oct-17 7:14am View
   
Hello digimanus,

It is not as easy as it looks but, as far as I can understand your problem, you can take advantage of Take and Range methods of the Enumerable class. Use the columnNames.Count to take the collection of labs and vars and update them using a for each.

Hope it helps.
GKP1992 5-Oct-17 5:28am View
   
Thanks for the details. Can you also share the table structure, I'm not sure why you need the column names in the inputFile. If they're going to be based on the number of columns in the excel file, why not update the columns sequentially using a foreach loop and update the rest with nulls?
GKP1992 5-Oct-17 4:26am View
   
There are 3 quite helpful links in the solution to the question asked in the link. Question are somewhat similar.
GKP1992 5-Oct-17 2:22am View
   
Exactly my thoughts.
GKP1992 5-Oct-17 1:30am View
   
Hello digimanus,

Can you give an example to clarify the problem?

Thanks.
GKP1992 5-Oct-17 0:18am View
   
Few questions:
1. What do you mean by resetting the code?
2. Do you mean you decompiled an assembly to get the code?
3. How do you want to use the code?
If you just want to encrypt something you can just add a reference of the assembly you decompiled to your project, and call the method you are trying to "reset" with the text you want to encrypt. Pretty straight forward. Beyond that, it is a research topic. You are on your own.
GKP1992 4-Oct-17 8:24am View
   
Please be more clear about what you want to do and where you are having a problem. Use the Improve question button to, well, improve your question.
GKP1992 4-Oct-17 8:18am View
   
What do you mean by a perfect solution?
GKP1992 4-Oct-17 2:33am View
   
SPAM
GKP1992 4-Oct-17 2:32am View
   
SPAM
GKP1992 4-Oct-17 2:29am View
   
You can try to have a column selected in your data set, set them to true in javascript when selecting. Then access on the next page (or anywhere you want based on the accessibility of your data set).
GKP1992 4-Oct-17 2:19am View
   
Possible duplicate to https://www.codeproject.com/Questions/1209015/What-is-the-correct-way-to-code-the-last-print-lin
GKP1992 4-Oct-17 2:18am View
   
Please do not spam a question. Your previous question is already getting some attention.
Please bear in mind that no one is going to do your assignment for you, we can only help.
GKP1992 4-Oct-17 2:15am View
   
Possible duplicate to https://www.codeproject.com/Questions/555113/isplusthereplusanyplustoolsplusavailable
GKP1992 4-Oct-17 1:47am View
   
Can you please explain what you want your program to do? How the methods behave and how your final grade is calculated?
GKP1992 4-Oct-17 0:14am View
   
I cannot say what is the problem you face but multiple return statements in a single code flow never work. A return statement means that the execution of the code block (in this case the method) is finished and the control will exit the method, so for your grades method, after the line
return round2(weightedHomeworkScore);
nothing will be executed. You might wanna reconsider your method and think about what you want it to do.
GKP1992 3-Oct-17 5:18am View
   
If that solved your question, please select an answer so that the question can be closed.
GKP1992 3-Oct-17 4:55am View
   
I get where you're coming from. Notice the placing of the commas in the text. It is the Indian number format not the international one. May be he wants to ask how to format with Indian culture. I gave a link to an SO question asking exactly that.
GKP1992 3-Oct-17 1:14am View
   
Debugging doesn't work?
GKP1992 3-Oct-17 1:14am View
   
Deleted
Debugging doesn't work?
GKP1992 2-Oct-17 3:49am View
   
Try debugging. It usually solves the problem.
Try https://msdn.microsoft.com/en-us/library/mt243867.aspx
and https://msdn.microsoft.com/en-us/library/k0k771bt.aspx .
GKP1992 18-Sep-17 3:46am View
   
Not much. But I have looked at this https://vsavkin.com/migrating-angular-1-applications-to-angular-2-in-5-simple-steps-40621800a25b, it seems good but it does not say anything about being able to run the angular 1 and 4 components together. (Sorry to not have mentioned that in the question I'll update it.)
GKP1992 8-Sep-17 4:25am View
   
I sympathize with you, but there is no easy way to learn something. You have to dive into it headfirst. If you do not understand what is written in the books. I suggest you find a teacher near you. It'll help you understand the basics of computer programming. Forums are only going to help you when you some understanding of the subject, since these are people who help other people voluntarily. If you do not respect that and expect them to do your homework, they are not going to like it.

And this is for you.

Aquele que faz uma pergunta é um idiota por cinco minutos; Aquele que não faz uma pergunta continua a ser um tolo para sempre. - Provérbio chinês
GKP1992 31-Aug-17 11:15am View
   
@forte74 you should notice that Thomas wrapped the stream object inside a using block.
That is a good practice for disposable objects and makes sure that the stream is closed after the task is finished.
GKP1992 28-Aug-17 4:36am View
   
I suggest you have a look at other CP questions and take some ideas for posting questions. Or read the rules. You are not making a lot of sense here. It is hard to know what you want with your code? What is the problem you face? If feels like you are very new to programming so I suggest you to take smaller steps. Importing excel data to SQL comes later. But if you wish you can take a look at SSIS solutions.
GKP1992 23-Aug-17 9:21am View
   
Shouldn't it be zero for Value2 column? Since the value comes back to 500 on 17-01-2017 and it is never below -1000 for 5 or more days.