2 Replies - 329 Views - Last Post: 27 April 2013 - 04:34 AM Rate Topic: -----

#1 Keylogger  Icon User is offline

  • D.I.C Regular

Reputation: 7
  • View blog
  • Posts: 344
  • Joined: 14-February 11

[Solved] Problem with getting the "mask" of access

Posted 27 April 2013 - 03:40 AM

Hi guys.

I have an ID field with automatic increment, etc. However, this field have a mask.
I'm wondering if it's possible, in code, to get the Mask and not the Index.

Because, whenever I select the data, it retrieves me the Index (1, 2, 3, 4), instead of (1001, 1002, 1003).

Ok, I thought about a possible solution: Just increment (1000 + i)..but there's records missing..so it won't display properly.

for (int i = 0; i <= DSet.Tables[0].Rows.Count - 1; i++)
  {
    dataGridView1.Rows.Add(1000 + i, DSet.Tables[0].Rows[i].ItemArray[0], DSet.Tables[0].Rows[i].ItemArray[1]);
  } 


I'm wondering if this is even possible?

This post has been edited by Keylogger: 27 April 2013 - 03:46 AM


Is This A Good Question/Topic? 0
  • +

Replies To: [Solved] Problem with getting the "mask" of access

#2 Keylogger  Icon User is offline

  • D.I.C Regular

Reputation: 7
  • View blog
  • Posts: 344
  • Joined: 14-February 11

Re: [Solved] Problem with getting the "mask" of access

Posted 27 April 2013 - 03:46 AM

Well..whenever I post something in DIC, I always get the response I'm looking in google for several minutes/hours.

I just had do SELECT `id`, then:

dataGridView1.Rows.Add(1000 + DSet.Tables[0].Rows[i].ItemArray[0], DSet.Tables[0].Rows[i].ItemArray[1], DSet.Tables[0].Rows[i].ItemArray[2]);


Thanks!
Was This Post Helpful? 1
  • +
  • -

#3 codejunky  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 20
  • Joined: 18-April 13

Re: [Solved] Problem with getting the "mask" of access

Posted 27 April 2013 - 04:34 AM

LOL!! Most people try google first.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1