3,183 Posted Topics

Member Avatar for eriekasato_1

The percentage is a string, which makes things a bit more difficult as you have to convert that to something you can use in a mathematical expression. Let's say `InsurancePercent` is of the form "###%". The process would be some variant of this: var percent = Convert.ToDouble(patient.InsurancePercentage.TrimEnd('%')); var insuredAmount = …

Member Avatar for eriekasato_1
0
315
Member Avatar for theonebit

A `DataTable` is the back end container for data, it corresponds roughly to a database table. A `DataGrid` or `DataGridView` is a UI control for displaying tabular data. It may or may not bind to a `DataTable`. I'm not sure what controls those applications use, they may be custom grid …

Member Avatar for deceptikon
0
211
Member Avatar for Dani

I'd use the homepage more if Fred and the new discussion panels didn't take up so much room. Perhaps you could add a way to collapse those and store the preference in a cookie?

Member Avatar for happygeek
1
828
Member Avatar for Wael1988

> i do always study but always forget..i feel sumties like stupid !! You remember what you use often, and references are there for what you don't use often. Don't feel bad, there isn't a programmer in the world who can remember everything, and it gets harder to remember as …

Member Avatar for Wael1988
0
202
Member Avatar for darrylnuyda

`OpenConCls.ToString()` will give you a default object representation because you didn't override `ToString`. This won't be a string that represents a valid integer, so `Convert.ToInt32` fails. By auto number I assume you mean the result of the query, which would be done like this, if I recall correctly: string pcount …

Member Avatar for deceptikon
0
2K
Member Avatar for CreatorZeus

> You can set the delimiter for getline(). Indeed, but only one delimiter. If the line doesn't end with `'.'`, input will span multiple lines. A full solution would use `getline` from the file to read a whole line, then `getline` with `'.'` as the delimiter from a `stringstream` of …

Member Avatar for deceptikon
0
260
Member Avatar for princessashisharma
Member Avatar for Aisha_1

Hey, I have an idea! How about you do your own homework instead of asking other people to help you cheat?

Member Avatar for nahi
0
247
Member Avatar for haider885
Member Avatar for Ancient Dragon
0
767
Member Avatar for elie.karkafy
Member Avatar for mrnutty

Mine was almost a random choice when I couldn't come up with anything better. The misspelling is intended to differentiate myself a little bit from the rather pervasive correct spelling from Transformers. Other candidates included ragecoder, algorhythm, and James2.

Member Avatar for Reverend Jim
0
687
Member Avatar for pritaeas

> but seriosly, the drinking age should be increased... (my opinion) Age doesn't equate to maturity, unfortunately.

Member Avatar for diafol
0
981
Member Avatar for mixelplik

The downside is that `using namespace` will make the entire namespace visible, even if you don't want all of the names to be visible. There's risk of naming clashes. Prefixing `std::` is more verbose, but also imposes no risk of name clashes. For namespace `std`, it's really just a matter …

Member Avatar for mixelplik
0
280
Member Avatar for VB user

Using ADO.NET to connect with an Access database is straightforward. Can you post your most recent code that doesn't work? Start by doing just the bare minimum in a console mode program so that all of the unnecessary fluff doesn't get in the way.

Member Avatar for Reverend Jim
0
279
Member Avatar for Hinata_Dev
Member Avatar for faris.hamarshi

What content? You always free `buffer` (also note that it's a local pointer and not accessible outside of the function) and never populate `text`. The function certainly reads a file, but it doesn't do much more than that.

Member Avatar for Mouche
0
186
Member Avatar for Pratique

Until you really know what you're doing, it's a good idea to compile code you want to show off before posting it.

Member Avatar for Mouche
0
349
Member Avatar for Builder_1

Start by making sure that your driver is working the way you want using a standard sorting library. Here's one that uses `qsort` in C-style since you're into C-style strings: #include <cstdlib> // std::qsort is here #include <cstring> #include <iostream> using namespace std; namespace { const int COUNTRY_MAX = 5; …

Member Avatar for Builder_1
0
1K
Member Avatar for msareef

And? What have you tried? Please note that our rules disallow posting homework questions with no proof of effort as if you wanted *us* do write it for you.

Member Avatar for Mouche
0
3K
Member Avatar for ujwal vohra

Break your program down into pieces. First I'd write a test console program that implements an LSB method for monkeying with bytes and ensure that it works the way I want. Then I'd write a GUI program to load an image and enumerate it's bytes, then save it. Finally, I'd …

Member Avatar for ujwal vohra
0
98
Member Avatar for Ancient Dragon

> There were a few changes to .NET Framework 4.5 support, which in the business world is a no-go until Windows 8 is adopted (unlikely in the near future from my consulting experience) or IT departments are comfortable installing the runtime to support applications written for it (more likely, but …

Member Avatar for G_Waddell
0
304
Member Avatar for mmcdonald

I'd start with something like "Applicants must be of legal age in their country of citizenship". But this is definitely something that should be written with the consultation of a lawyer.

Member Avatar for G_Waddell
0
337
Member Avatar for Warrens80

> And I have become confused on what this thread is about... I'd wager it's about the OP boosting his post count with pointless posts.

Member Avatar for GrimJack
-13
641
Member Avatar for Sara_6
Member Avatar for JOSheaIV

> When I import the DLL I have created into another project to test, it complains about missing the reference `System.Drawing.Bitmap` is a .NET standard class. The library assembly itself doesn't require you reference `System.Drawing` in the application that references your library, but if you expose the `Bitmap` class as …

Member Avatar for Ketsuekiame
0
384
Member Avatar for venkates.99

What goober wrote those questions? Question 95 is especially entertaining given the acronym vomit of its multiple choice answers, but most of the questions are amusing.

Member Avatar for deceptikon
-1
487
Member Avatar for osagie.odigie.77

> if u dont have an answer to my post>>>>>>>>>>>>>>>>>>>>just SHUT up . Last I checked, this was a public forum. AD makes a good point. Your writing style makes a strong first impression, and it's not a good one. That said, I have an answer to your post. Discussion …

Member Avatar for mike_2000_17
-1
225
Member Avatar for supernova122

The error seems straightforward to me. `String` and `DBNull` are incompatible types, so you need to handle them separately: If dataview(0)("name") = DBNull.Value Then ' Handle a null name Else ' Handle a non-null name End If How you handle the name depends on what your "..." part does.

Member Avatar for supernova122
0
287
Member Avatar for foreba

When you're storing a list of entities in a column, that suggests you have shared data which can be normalized. Let's take your names example and make up something to show the setup. Denormalized business_unit: bu_id, managers, address -- Separating the manager names is a chore select managers from business_unit …

Member Avatar for deceptikon
0
256
Member Avatar for inspire_all

A segmentation fault means you accessed memory you don't own. The two most common causes are a pointer that's not properly initialized an an index outside the bounds of an array. Trace through your code and ensure that all of your pointers point to enough memory, then make sure all …

Member Avatar for deceptikon
0
202
Member Avatar for Ancient Dragon

You can also simply click on the NEW icon next to the forum name (on the home page) to mark it as read.

Member Avatar for Ancient Dragon
0
218
Member Avatar for @di007
Member Avatar for Assembly Guy
0
111
Member Avatar for Patrick_3

Try increasing the z-index or just `BringToFront` on the control if you want it at the top level.

Member Avatar for Patrick_3
0
1K
Member Avatar for @di007

Stack overflow is when you put too much stuff on the stack. It's usually triggered by excessive recursion. Access violation to 0x0 is when you try to write to a null pointer. Stack corruption is a little more subtle. It happens when you do someting like write beyond the bounds …

Member Avatar for deceptikon
0
148
Member Avatar for visya

Simple: don't do that. To store arbitrary binary files in a table you'd need to use blobs, and I can tell you from experience to avoid blobs where possible. A better approach is to store the files on the file system, then store the *path* to them in your table. …

Member Avatar for JOSheaIV
0
236
Member Avatar for Chinney

> Many experts program with a plain text editor most of the time. Professionals will use any tools necessary to speed up the process, but as it's sometimes said, the tools don't make the programmer. A good developer shouldn't be handicapped if you take away his IDE, he'll just switch …

Member Avatar for Chinney
0
317
Member Avatar for newbie14

The ideal would be to properly parse the HTTP protocol format, but for this specific case it's straightforward to extract the address (error handling omitted for brevity): #include <stdio.h> #include <string.h> int main(void) { const char *request = "GET /mail/ HTTP/1.1\r\n"; const char *paddr_begin = request + 4; const char …

Member Avatar for newbie14
0
143
Member Avatar for greatman05

That's simple enough: `args` is an *uninitialized* pointer, not a pointer to infinite memory. To simulate a 2D array you need to first allocate room for the number of pointers you want, then allocate memory to each pointer. Same thing with `pipe_args`. The pattern is this: char **args = malloc(10 …

Member Avatar for greatman05
0
259
Member Avatar for alina.nazchowdhury
Member Avatar for deceptikon
0
93
Member Avatar for Carlos_9
Member Avatar for Alonso_1

Keep a frequency table: int numbers[] = {1, 4, 5, 5, 5, 6, 6, 3, 2, 1}; int freq[10] = {0}; for (int i = 0; i < sizeof numbers / sizeof *numbers; i++) { if (numbers[i] >= 0 && numbers[i] < 10) { ++freq[numbers[i]]; } else { printf("Invalid digit: …

Member Avatar for deceptikon
0
3K
Member Avatar for Nagy Razvan
Member Avatar for deceptikon
0
42
Member Avatar for CoolAtt

> 1.if .net is a wrapper around win32 api it means we are able to do everything with .net that we used to do with win32 api. then why we still need the p/invoke to the win32 api? Because there's not a .NET interface to *all* of the Win32 API. …

Member Avatar for deceptikon
0
304
Member Avatar for pandeysk_13

To clarify my own understanding: * The grid contains agents * All displayed agents are bound by a single parent * The text box contains a total amount tied to the parent * Agents must be shared a part of the total amount based on their commission percentage If all …

Member Avatar for pandeysk_13
0
259
Member Avatar for furalise

That's because your `stringstream` really does only contain the first word. Why? You used `operator>>` to populate mystring from cin, and `operator>>` stops reading at whitespace. Try using `getline` instead.

Member Avatar for furalise
0
440
Member Avatar for Warren_1

Without seeing the code, it's hard to tell. `malloc` and `realloc` will return `NULL` on failure, but there are gotchas that could appear to work yet still be subtly broken. Can you post a small sample of how you're allocating, using, and releasing your memory?

Member Avatar for deceptikon
0
384
Member Avatar for castajiz_2

First and foremost, your code exhibits undefined behavior because you only ever initialize the first character of the string. The actual problem you're seeing though, is that you only store one character at a time in `string[0]`, and it gets replaced with each iteration of the file reading loop. The …

Member Avatar for deceptikon
0
151
Member Avatar for sushilsth

Note that the process which has the file open could be *your* process, if you've opened it before and failed to close it or try to open it again before disposal completes. I'd strongly recommend downloading and learning how to use [Process Monitor](http://technet.microsoft.com/en-us/sysinternals/bb896645.aspx) to troubleshoot these types of errors. That …

Member Avatar for deceptikon
0
175
Member Avatar for harisybsy

For simple 1D barcodes like 3 of 9 or 128, you shouldn't need a barcode generator, just a font. The encoding of the value itself is straightforward with start-stop characters and in the case of code 128, a simple check digit calculation before the stop character. From there it's just …

Member Avatar for deceptikon
0
451
Member Avatar for Jamblaster

This thread is clearly inflammatory, but I'm letting it slide because there's potential for good discussion *iff* everyone remains civil. Please keep that in mind, thanks.

Member Avatar for diafol
1
376

The End.