|
hello, im looking for some help in sending a file in a client server enviroment using winsock,i have managed to do this in the past using a small text document however i face problembs when using lareger files that wont fit into a small char buffer.
my aim is to divide my file up into chunks,and individualy send theese chunks of data to the server, wich inturn will reasemble the data and write the file to a directory.
i face problembs in knowing agsactly how to divide the file up into chunks,and how to reasemble the file at the server side,also i have problembs in knowing when the file has been completley sent and completley recived. any information that could be relevant to helping me would be greatly appreciated.
thank you for your time.
|
|
|
|
|
|
hello
i am develeloping a project in vc++ of Remote Administrator
in Workgroup model.I want to connect to another computer
in workgroup by wnetaddconnection2 function
features of my project is
1.control of services by openscmanager
2.remote shutdown
3.control of process on remote system
can somebody help me
viksd jindal
|
|
|
|
|
vikasjindal wrote:
can somebody help me
Can you narrow it down a bit? What exactly do you need help with? Is a piece of code giving you troubles? Do you not know how to use WNetAddConnection2() ?
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Hi,
I include a modeless CDialog into my program by :
m_pDlgRelance = new CDlgRelance(); // CDialog
BOOL ret = m_pDlgRelance->Create(IDD_DLG_RELANCE,this);
if(!ret) //Create failed.
AfxMessageBox("Error creating Dialog DlgRelance");
m_pDlgRelance->ShowWindow(SW_SHOWNORMAL);
But it appear always over the parent windows.
What can i do to avoid this ?
Thanks
Best Regards
Olivier JOLY
|
|
|
|
|
try this
BOOL ret = m_pDlgRelance->Create(IDD_DLG_RELANCE,NULL);
|
|
|
|
|
Thanks,
But tested without result
Best Regards
Olivier JOLY
|
|
|
|
|
If you pass NULL it creates the dialog with the application window as parent.
Ant.
I'm hard, yet soft. I'm coloured, yet clear. I'm fruity and sweet. I'm jelly, what am I? Muse on it further, I shall return! - David Williams (Little Britain)
|
|
|
|
|
olivierjoly wrote:
BOOL ret = m_pDlgRelance->Create(IDD_DLG_RELANCE,this);
replace this
with
GetDesktopWindow()
Ant.
I'm hard, yet soft. I'm coloured, yet clear. I'm fruity and sweet. I'm jelly, what am I? Muse on it further, I shall return! - David Williams (Little Britain)
|
|
|
|
|
Thanks a lot ... It's works
Olivier JOLY
|
|
|
|
|
Hello all!
I have following problem - i need to finish my program, which executes in background, when user finish windows. My program doesn't have windows - and i cannot receive messages.
This is a scheme of my program:
while ( flag )
{
Sleep(1000);
if ( need_Action )
{
..do action..
}
}
Thanks!!!
------
Vladimir
|
|
|
|
|
Why not make it a windows service?
"It was when I found out I could make mistakes that I knew I was on to something."
-Ornette Coleman
"Philosophy is a study that lets us be unhappy more intelligently."
-Anon.
|
|
|
|
|
Unless you can respond to the WM_QUERYENDSESSION and/or WM_ENDSESSION messages, you'll have no way of knowing when Windows is shutting down or when a user is logging off.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
hi!
i would like to implement a html-site - a small html-template with a few controls like a slider, buttons and so on...
the user should be able to change the look of the application by just editing the html-template.
from within c++ i want to get info, if the user clicks a control (button, slider...) and i want to change eg. the position o f a slider, content of a listbox, text of a button...
the template has to be embeded in the main application... the main-framework should be a CDialog
is it possible to do this without requesting the user to install ie6 or something?
the app should also work, if just a minimum iexplorer is installed.
or is there a way to do this without ie?
how do i interact with the html-template from within my c++-code?
has anyone a idea or tutorial? maybe some demo-classes on thecodeproject.com? i actually don´t know, what i have to search for ;o)
cheers,
vertex_X
|
|
|
|
|
Hi
Let's say I defined a global const in a header file (which will be #included by many files) as follows:
const int MAX_CLIENT = 1000;
My question is, will the compiler replace each occurence of MAX_CLIENT with 1000? Should I declare MAX_CLIENT as static const instead? And will the same rule apply if MAX_CLIENT is not an int, but a char array?
Thanks!
|
|
|
|
|
Indrawati wrote:
will the compiler replace each occurence of MAX_CLIENT with 1000?
Yes and no . It's not a direct textual substitution like a #define , but when the compiler is optimising code it will substitute the variable reference by its value.
Indrawati wrote:
Should I declare MAX_CLIENT as static const instead?
If your header file is used by multiple source files, then yes, otherwise you'll get a bunch of multiple initialisation errors from the linker.
Indrawati wrote:
And will the same rule apply if MAX_CLIENT is not an int, but a char array?
Yes. If it's a char* though, such as char *message = "Message" , then make it fully constant, ie. const char * const message = "Message" , otherwise the compiler might not treat it as a true constant.
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
i have an existing library which provide me the support for calling varied functions. now i ahve to add the functionality of two new api's in that same vc project which eventually will be called by the autocad application. i ahve with the objectarx require to create the glue layer and the arx application which will hwlp me call the funtions in vc through autocad. even though i have created a new library which defines the two api's but on calling these functions through VC++ it shows me an error that it cannot find the new api's called even thought the new library has been included in the project setting. please guide as to where am i missing the link as there are quite a few things involved in interacting autocad with vc.
sachin jain
Software Developer
|
|
|
|
|
Have you set the include and lib paths so that they cover the location of your libraries and headers?
Ant.
I'm hard, yet soft. I'm coloured, yet clear. I'm fruity and sweet. I'm jelly, what am I? Muse on it further, I shall return! - David Williams (Little Britain)
|
|
|
|
|
thanx for thr reply but i am a bit uncertain. if u r mentioning the include and library paths for object arx, then they have been included and also the path for the library(for the new API's that i need to include) has also been included in the project settings. hence, plz be more specific as to what include and lib paths are u talking about. looking forward to ur reply but still thanx in advance.
|
|
|
|
|
I was refering to the directory settings under Tools->Options. You can specify global settings for include paths and library paths.
If you have these settings can you give the exact error message you are getting when you try to compile.
Oh, just a thought, Have you tried a complete clean and rebuild?
Ant.
I'm hard, yet soft. I'm coloured, yet clear. I'm fruity and sweet. I'm jelly, what am I? Muse on it further, I shall return! - David Williams (Little Britain)
|
|
|
|
|
it is said that there are some hooks that can only be set in the dll(means a global hook) not be set in the application(a local program hook),is it right?
if true,could you tell me which hook can only be set in dll,thanks a lot
|
|
|
|
|
yingkou wrote:
if true,could you tell me which hook can only be set in dll,thanks a lot
Any hook which can get called in the context of a thread that does not belong to the process that installs the hook must be in a DLL. So basically, any system-wide hook. Thread-specific hooks that only hook threads in the current process can reside in the application.
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
sorry to interupt to you again,I don't understand what you said? please give my a clear answer,thanks
|
|
|
|
|
If the hook is a global hook, it must be in a DLL. If it is not a global hook, it can be in your application.
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
I want to know which hook can only be a global hook not be a hook for one program
|
|
|
|