|
Ok, the hard drive never completely fails! We just get some error about bad or damage files & sectors. I plan on attacking this problem in two ways. First Trying to limit or control hard drive activity. I really only need to limit the write activity. Cause, If I can limit the hard drive write activity. I can go to solid state drive which would resolve the problem. As you all probably know, solid states drives can only perform a limited number of writes. So, if i don't limit the write activity the drive will only last a week. Which means i really way to ensure the virtual memory is only used rare cases. The OS can pretty much be lock down.
Scott
Scott Dolan
Jernie Corporation
Engineering & Manufacturing
Software, Hardware, & Enclosures
|
|
|
|
|
ScotDolan wrote: As you all probably know, solid states drives can only perform a limited number of writes.
Such as USB drives? I did not know they had a limited life span.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Not a USB drive but, Flash based SATA drive from m-systems which was purchased by SanDisk.
Scott Dolan
Jernie Corporation
Engineering & Manufacturing
Software, Hardware, & Enclosures
|
|
|
|
|
1. I've got some application written in Java.
2. I don't want to interfere in the program's source code
3. This application works on Win 2k using cmd.exe only. It doesn't
have graphics interface. I can start it directly with cmd.exe, or
by using the bat file.
4. My question is:
Can I get in the console application from outside? I mean, Is it
possible to take it on with some other program (lets say some kind
of strap) working in GUI? I would like to launch my new strap
written in c++ whereby I could not only start the given console
application but also work on it sending/receiving data/commands.
Which functions/librarys should I use?
For example: Using CreateProcess I could possibly start the
application in cmd.exe, but what next? How to cooperate with it?
5. I tried to use
http://www.codeproject.com/useritems/ConsoleAdapter.asp[^] , but system commands sent to such a console haven't work, also
attaching to cmd.exe haven't helped.
6. I don't know exacly which forum should I use to ask about my
problem, so be patient with me, and give me bearing to proper one.
Please, give me some advice, and sorry for my pure :] yyy rather poor English
|
|
|
|
|
Newbie00 wrote:
Can I get in the console application from outside? I mean, Is it
possible to take it on with some other program (lets say some kind
of strap) working in GUI? I would like to launch my new strap
written in c++ whereby I could not only start the given console
application but also work on it sending/receiving data/commands.
Which functions/librarys should I use?
See here and here.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Thanks, I've used the first link (you had given me) to my project and it works I can write/read commands to CMD.exe by clicking buttons :]. All I've to do now is to prepare appropriate commands, and I think, I'll be able to use the application, that I'd mentioned in my question. that's great thanks again for your reply :]
|
|
|
|
|
Hi,
I'm encountering a problem with my ActiveX control. This control needs to be visible throughout the life of the application because of a Client/Server relationship.
I'm using a View type of application. Currently, I'm getting an ASSERTion error from winocc.cpp, line 345. After doing some research, this error is seemingly caused by attempting to instantiate an ActiveX control without really adding the control to an instance form.
Currently, I've created a member var in my App class that is public.
Such as:
CClient m_conn.
However, that is clearly not enough to invoke the object correctly. I'm now under the impression that the control needs to be on a form. My problem is I do not know what form to place this control on.
So, I ask CodeProject: What form should I place my ActiveX control on in order to make it visible to the entire application throughout the application's life-time?
Do I have to make a dummy form, such as initclientdlg; then, instantiate the dialog but never call DoModal() or whathaveyou?
Thank you in advance.
|
|
|
|
|
hi all
i would like to know how can v delete a folder that contains files.i have an application which will create some files with 'xyz' extension into a diectory while clicking a button. i know only file extensions but no file names.while exiting the application i want to delete the direcory with that files.. i know we can find files & then we can deletefile function & finnaly we can delete directory. is it possible to use FindFirstFile by providing folder path & extension instead of file name. please give me replay....
|
|
|
|
|
|
hi
thanx for ur replay. can u explain the SHFileOperation as it required the file names. but i dont know the names of files which are created in my folder that i want to delete.
|
|
|
|
|
|
How does one open a Bitmap image. I am working on the VC++ platform for my project
|
|
|
|
|
give more details about wat you already have please
have you search for some examples at first ?
|
|
|
|
|
what about LoadImage ?
with something like ?
HBITMAP hBitmap = (HBITMAP)::LoadImage(NULL, sFileName, IMAGE_BITMAP,
0, 0, LR_LOADFROMFILE | LR_DEFAULTSIZE | LR_CREATEDIBSECTION);
|
|
|
|
|
Yes, dats wat i wanted.
Sorry, couldnt specify details.
Need to load bitmaps, calculate pixels n colors...
Wat wud be the best model for colors, preferably, ARGB?
|
|
|
|
|
And see CImage class if you want to open other formats
|
|
|
|
|
could anyone plz tell me how can i intialized
unsigned short int test_array[256][256] to zero or empty
Thanks!
|
|
|
|
|
Brutal method:
for (int i = 0; i < 256; i++) {
for (int j = 0; j < 256; j++) {
test_array[i][j] = 0;
}
}
wiser one:
::memset(test_array, 0, sizeof(unsigned short int)*256*256);
[edit]
-- modified at 12:08 Thursday 15th February, 2007
Better one:
unsigned short int test_array[256][256] = {0};
thanks David
[/edit]
|
|
|
|
|
toxcct wrote: wiser one:
::memset(test_array, 0, sizeof(int)*256*256);
Which would actually not be very wise as an int is twice as large as an unsigned short .
memset(test_array, 0, sizeof(test_array));
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
i'm really confused, i read int at first, not unsigned short int
by the way, i prefer writing the explicit
sizeof(unsigned short int)*256*256 instead of
sizeof(test_array) because i find it more clear in the reader's mind.
of course, if the array change of type, my code must be adapted, not yours.
|
|
|
|
|
::memset(test_array, 0, sizeof(int)*256*256);
thanks but how can be done in C langauge.
|
|
|
|
|
firstly, check the code, it's been modified (with unsigned short int instead of int in the sizeof() )
secondly, the code is quite C. remove :: before the memset, and all the remaining is C code.
don't forget however to #include <stdlib.h>
|
|
|
|
|
unsigned short int test_array[256][256] = { 0 };
memset(test_array,0,sizeof(test_array)); If you need to clear the array sometime after it's definition.
Software Zen: delete this;
|
|
|
|
|
you didn't read the other posts in the thread, did you ?
here[^] is what i told David about this...
|
|
|
|
|
ikbahrian wrote: could anyone plz tell me how can i intialized
unsigned short int test_array[256][256] to zero or empty
Like:
unsigned short test_array[256][256] = {0};
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|