Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

hello all,

 

if I have a table like

 

Dim TblWerknemers As String(,) = {{"code", "3", "7", "8", "9", "10", "12", "13", "15"}, _

{"naam", "De Smet", "Janssens", "Pieters", "Cornelis", "De Smet", "Van Acker", "De Grootte", "Martens"}, _

{"afdeling", "marketing", "verkoop", "verkoop", "expeditie", "verwerking", "marketing", "verkoop", "verwerking"}, _

{"loon", "800", "900", "900", "750", "1000", "950", "1000", "850"}}

 

 

and I want to add extra values in the table, I first do

redim preserve tblwerknemers(tblwerknemers.getupperbound(0), tblwerknemers.getupperbound(1) +1)

 

 

then I dont know how to put new values in the table.

I know in theory how this works but I dont know how to write it

 

if anyone could point me to some usefull information or an example....

 

 

thanks

 

DuSti

  • Leaders
Posted

First, I don't think you need the comma between the two parentheses. () should be fine.

And, for putting information into the table, just do this:

 

N = TblWerkNemers.GetUpperBound(1)

TblWerkNemers(0, N) = "16"

TblWerkNemers(1, N) = "Erikson"

TblWerkNemers(2, N) = "marketing"

TblWerkNemers(3, N) = "1000"

:)

 

Of course, you can load the data from somewhere, and just use variables:

TblWerkNemers(0, N) = sNewCode

Iceplug, USN

One of my coworkers thinks that I believe that drawing bullets is the most efficient way of drawing bullets. Whatever!!! :-(

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...