Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
R

Roger CS

@Roger CS
About
Posts
13
Topics
3
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Drawing on a tabPage
    R Roger CS

    I would like to display read-only information on a tab page by simply drawing it using GDI (TextRenderer.DrawText). The problem I'm having is that the text is not persisted by the tabPage surface itself. If I select a different tab then switch back the text is lost with the redwaw. If I use Label controls the control handles persisting the text. What do I need to do to be able to draw on a tab page and have the text stay there until I'm ready to change it? Labels aren't going to cut it. -Roger

    C# graphics help question

  • Begin printing at row x column y
    R Roger CS

    I wrote a report. I was just printing the report. I hadn't gotten any further than that when I posted this question. What I have learned since then is that I can print lables using the PrintDocument class. I just need to extend the functionality to meet my requirements.

    C# database sql-server sysadmin tutorial question

  • Begin printing at row x column y
    R Roger CS

    led mike wrote:

    I suggest you do some reading about how to do printing

    Yup, you were right. Everything I needed to know was there... I just had to extend PrintDocument and add some functionality. Thanks, Roger

    C# database sql-server sysadmin tutorial question

  • how to write?
    R Roger CS

    Essentially you have four things you can do: SELECT, INSERT, UPDATE and DELETE. When you edit a record you first SELECT the record, make changes then use UPDATE to save the changes to the database. Go to msdn.com and click the Library link, search for OleDbDataAdapter. Here's an example from... public DataSet CreateCmdsAndUpdate(DataSet myDataSet,string myConnection,string mySelectQuery,string myTableName) { OleDbConnection myConn = new OleDbConnection(myConnection); OleDbDataAdapter myDataAdapter = new OleDbDataAdapter(); myDataAdapter.SelectCommand = new OleDbCommand(mySelectQuery, myConn); OleDbCommandBuilder custCB = new OleDbCommandBuilder(myDataAdapter); myConn.Open(); DataSet custDS = new DataSet(); myDataAdapter.Fill(custDS); //code to modify data in dataset here myDataAdapter.Update(custDS, myTableName); myConn.Close(); return custDS; }

    C# database tutorial question

  • Extracting files from inside a file archive
    R Roger CS

    Do you have any other files that accompany this file? I'm asking because a data file like you are describing would commonly have an index, either embedded in the data file or in a separate file. If you had the index you could position to the offsets and read. If you don't have an index you'll probably have to read sequentially and detect headers as you go. As far as efficiency is concerned... don't optimize unless the method you're using is too slow. In that case you want to find the bottlenecks and open them up.

    C# regex tutorial question workspace

  • Begin printing at row x column y
    R Roger CS

    Dave Kreskowiak wrote:

    Your description isn't very clear

    I’ll try to be clearer. I am printing mailing labels. The sheet of labels has 3 columns and 10 rows (for a total of 30 labels). Normally people don't need to print exactly 30 labels or multiples of 30. Instead they may need to print 10, then later 6 more and so on. If the user starts with a fresh sheet and prints 10 labels, there will be 20 labels remaining. The next time the user prints labels they need to start printing at label 11. For this reason, the program allows the user a way to enter the row and column at which to start printing labels. In this case the user would enter row = 4 and column = 2. I want to know how to start printing labels at row 4, column 2. The information in the labels is pulled from a SQL Server 2005 database using a select query. Thanks for the pointer to the KB article! Roger -- modified at 17:35 Saturday 13th October, 2007

    C# database sql-server sysadmin tutorial question

  • Begin printing at row x column y
    R Roger CS

    Anyone here who actually knows how to do what I'm asking about?

    C# database sql-server sysadmin tutorial question

  • Begin printing at row x column y
    R Roger CS

    I have written a report to print labels which works quite well as long as a full sheet is to be printed. Unfortunately in the real world people rarely print full sheets of labels. Instead they need to be able to specify a column and row to begin printing. The label report is actually a horizontal report that prints three rows then moves to the next column prints three rows and so on. The names and addresses are pulled from a SQL Server 2005 database. Is there a way to send printer codes to the printer to position the print head before printing begins? I've even thought about using dummy records to get the printer to skip to the right record, but I'm not sure how to do that or if it would even work. Any suggestions are appreciated.

    C# database sql-server sysadmin tutorial question

  • The Memory Hoax
    R Roger CS

    That is rich! :-) Thanks for the link! Roger

    The Lounge csharp html com performance question

  • query in rs232 programming in turbo c
    R Roger CS

    Hey, been awful busy this week and didn't notice that you replied. Check your parameter to bioscom. I think COM1 should be defined as 0 and COM2 would be 1. Your library implementation may be different. You should be passing 3 for the first argument to obtain the status, not 0. Take a look at this page for a complete discussion on bisocom... http://www.funducode.com/freec/Hardware/new_hi_c02/Article02.htm[^] Roger

    C / C++ / MFC database tutorial lounge

  • query in rs232 programming in turbo c
    R Roger CS

    What are you using to transmit the data?.. serial cable, modems? Have you confirmed that the hardware is configured correctly by opening a hyperterminal session on the transmitting PC and sending test data to the receiving PC using the same settings as you use in your program? You must make sure that the ports and hardware (serial cable or modems) are properly configured first. Then, if your program still does not work, start looking at the code for errors. Roger

    C / C++ / MFC database tutorial lounge

  • starting DirectX
    R Roger CS

    IMHO, compared with what is available on the net, the SDK samples are not bad for getting started. There is a DirectX forum at You'll probably get more leads to tutorials from the posters there. Good Luck with DirectX! -Roger

    C / C++ / MFC tutorial graphics game-dev

  • Respond to UI Messages
    R Roger CS

    I'm writing my first C# Windows Application using Win Forms. The program, a simple utility, is very processing intensive. Once the processing begins it continues for several minutes. I need the program to process UI messages while it is processing data, obviously. I'm not sure how to do this using the runtime. Would some kind person please point me in the right direction? Roger

    C# csharp design tools tutorial question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups