Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. stuartd

    Find the size of a dynamic array

    Ok, so cast is unnecessary However, if you do a google search for 'malloc', (almost) every code usage sample uses casting, as does my K&R C book. It is only if you search for 'cast malloc' you find how to really use malloc. Thanks to Salem for spotting the original error SD
  2. stuartd

    Find the size of a dynamic array

    Salem - i agree about the byte rather than pointer allocation. As for casting - I was under the impression that casting is required to ensure the return a pointer of the correct type (for pointer arithmatic), and it is best practice to cast. SD
  3. stuartd

    Find the size of a dynamic array

    Will option 2 be easy if i am using a dynamic array of structures? SD
  4. stuartd

    Find the size of a dynamic array

    Hi, I have a dynamic array which i need to find the size of to re-allocate more space to: char **dynamic_array; char *ptr; ptr=(char *)malloc(10); memcpy(ptr,"something\0",10); dynamic_array=(char **)malloc(1); dynamic_array[0]=ptr; ptr=(char *)malloc(10); memcpy(ptr,"nothing \0",10)...
  5. stuartd

    No logon servers available

    :``( I can not believe the MS security is so good the only way is to take 2 machines with me. There's got to be a work-around? SD
  6. stuartd

    No logon servers available

    Right - see your original point now. Unfortunately the server has to be moved, so the original problem needs to be resolved. SD
  7. stuartd

    No logon servers available

    Yes - my point exactly. Read the original post - i am having problems with windows security. SD
  8. stuartd

    No logon servers available

    Thanks for the replys. Seaspray0: IP has been configured. I have shared folder on remote machine (everyone and guest - all ticked,security . The problem is that the office machine does not prompt with login box or anything - you just get the error. Mark: Novel idea, but no good. Machine has to...
  9. stuartd

    Loggin automatically

    To bypass the login screen and automatically login in as the administrator, you need to run regedit and make the following resistry mods: Find key: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon Ensure the following properties are set (adding them if necessary)...
  10. stuartd

    No logon servers available

    I have a server which normally resides in an office on a domain. I have a remote location with a server which does not belong to a domain. I physically take the office server to the remote location to run a job, which involves copying files from the office server to the other server. The 2...
  11. stuartd

    No logon servers available

    I have a server which normally resides in an office on a domain. I have a remote location with a server which does not belong to a domain. I physically take the office server to the remote location to run a job, which involves copying files from the office server to the other server. The 2...
  12. stuartd

    Sleep function...zzzz....zzzz...

    NeilTrain - timer works great. It's easy when you know how! SD
  13. stuartd

    Sleep function...zzzz....zzzz...

    I need to copy files from one place to another, and will do it every 60 seconds. As this is external, i can not get an event. So to use the timer, my copy code would need to be called from the timer event function? SD
  14. stuartd

    Sleep function...zzzz....zzzz...

    Hi, I have written the following ugly function. This appears to hog all processor power, so there must be a better way to sleep in a program for a period of time. Does anyone have any suggestions? // Will sleep the program for given number of seconds private void Sleep(int i_SleepSeconds) {...
  15. stuartd

    Getting SqlDataAdapter.UpdateCommand to work

    Found a way of doing it string s_conn="[connection string]"; SqlConnection oConn = new SqlConnection(s_conn); oConn.Open (); SqlCommand oCmd; oCmd = new SqlCommand ("INSERT into Names(Title,Name) VALUES ('Mr','Bloggs')"); oCmd.Connection=oConn; int...
  16. stuartd

    Getting SqlDataAdapter.UpdateCommand to work

    I have managed to connect to a remote server DB and retriev a record using SqlDataAdapter.SelectCommand and putting the result into a DataSet. Now i want to update a table. The code appears to run through with no exceptions, but the DB never shows an update. Here is the code: string...
  17. stuartd

    Using DataSet object

    No reason (other than not knowing how to do it correctly in the first place). SD
  18. stuartd

    Using DataSet object

    Hi I am using the SqlCommand/DataAdapter/DataSet to read some records from a table. I then put the results into some text boxes. I am using Rows, and ItemArray : txtEventID.Text=oDS.Tables["Events"].Rows[x].ItemArray[0].ToString()...
  19. stuartd

    Client / Server

    So how do i get the required ip address (eg 192.168.6.16) to a long or byte[] if i want to do it by hand? (eg a client connecting to the server) SD
  20. stuartd

    Client / Server

    Hi, I want to write a server program accepting socket connections. So far i have: my_socket=new Socket(AddressFamily.InterNetwork,SocketType.Stream,ProtocolType.Tcp); g_ws.Bind(ENDPOINT); g_ws.Listen(10); So i need an ENDPOINT to bind - so far i have: IPEndPoint ep; ep=new...

Part and Inventory Search

Back
Top