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 SkipVought 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. doorbreaker

    Creating insert statements with excel

    Perfect! Thanks a lot for your help. I learnt a fair bit too about vba having to work through this. Chris
  2. doorbreaker

    Creating insert statements with excel

    Hey Skip, this works: Sub testtest() Dim r As Range, sPID As String, c As Range, sSql As String Open "Datafile.txt" For Output As #1 For Each r In Range(Cells(2, "B"), Cells(2, "B").End(xlDown)) With r For Each c In Range(Cells(.Row, "C"), Cells(.Row, "M")) With c If...
  3. doorbreaker

    Creating insert statements with excel

    Ok, I've done a bit of work on this but still having trouble: If a value is in a certain column then the appropriate value is written into the insert statement in the generated file: Sub test() Dim r As Range, sPID As String, c As Range, sSql As String Open "Datafile.txt" For Output As #1...
  4. doorbreaker

    Creating insert statements with excel

    thanks for the tips skip, i will look into how to write to a txt file. cheers chris
  5. doorbreaker

    Creating insert statements with excel

    No, I was hoping just to write them to a text file. Any ideas - is this difficult? Thanks
  6. doorbreaker

    Creating insert statements with excel

    This code doesn't seem to do anything at the moment. How do i write the insert statements to either a cell or external file? any help welcome thanks chris
  7. doorbreaker

    Creating insert statements with excel

    hi, i ran the macro and got the following line as having a syntax error: for each c in range(cells(.row,"C"), cells(.row,"C').end(xltoright)) any ideas what may be wrong? thanks chris
  8. doorbreaker

    Creating insert statements with excel

    I could send my excel sheet if that would help.... it might be a lot easier to see what i mean from that.
  9. doorbreaker

    Creating insert statements with excel

    oops sorry. in the insert i only need to insert the productid and the category. ah, i see the formatting on the page has gone awry. the productid is 1 and a 1 is used to show that rc is a category that should be attributed to productid 1. Does that make any sense?
  10. doorbreaker

    Creating insert statements with excel

    Hi, I'm a bit useless at using excel and was wondering if anyone can help me create an insert script for my database? At the moment on my worksheet I have the following: productname prodid rc spy fitness other testa 1 1 testb 2 1...
  11. doorbreaker

    From DB to excel using ASP - display probs

    Brilliant - thanks very much - worked a treat.
  12. doorbreaker

    From DB to excel using ASP - display probs

    Hi, I've been asked to provide a CSV with a whole load of products, their prices and descriptions from our db. After I've exported it using server.createobject ("scripting.filesystemobject") and try and open in excel the data is all over the place. I am assuming this is because of line...
  13. doorbreaker

    formula mini question

    hi, i am using the following formula to make an sql update statement in excel: ="update tablename set weight = '"&B2&"',name='"&C2&"',other='"&D2&"' where pk = "&A2 how do i add a comma (;) at the end? It errors if i try. Thanks Chris
  14. doorbreaker

    3 in a row record output - (tiled)

    Brilliant - thanks very much for this - it works perfectly! Also thanks then to the original helpers. Have a great day.
  15. doorbreaker

    3 in a row record output - (tiled)

    Hi, I want to display images in rows of 3. The image name comes from the database and I am going through the recordset and outputting each image. i.e x x x x x x x x x How do I do this? All I can do at the moment is have them like: x x x Can anyone help on this issue? Thanks
  16. doorbreaker

    Bar Codes??

    Ok, maybe it would be easier to see if what I need is possible if I spell it out exactly. We are currently printing off order details. These have labels to stick on the products to be delivered. There is also a barcode printed. Hopefully the people in the warehouse will be able to scan the...
  17. doorbreaker

    Bar Codes??

    Thanks for the thread. Do you think it would be possible to use a third party application that would update the sql server db directly (without the need for text boxes)? I could run some scheduled vbscript to check for updates to the db after the barcode scanning had been done. Just...
  18. doorbreaker

    Bar Codes??

    Hi, Does anyone have any experience of using and scanning bar codes to update their SQL Server database. I have just got an ASP barcode generator component working and I'm now at the next step of seeing how to let people scan these barcodes (once printed) to update the db. Any friendly...
  19. doorbreaker

    number compare

    thanks, this worked a treat :-)

Part and Inventory Search

Back
Top