locked
Changing a field type RRS feed

  • Question

  • Visual Basic program. I need to change a number field to a string field.  Access database is the BE. Do I change the Access field type then change the adaptor?  What is the easiest way to do this?
    • Moved by 宝宝徐 Tuesday, July 18, 2017 2:46 AM
    Monday, July 17, 2017 2:13 PM

All replies

  • Hi,

    This forum is discussing Visual Studio WPF/SL Designer, Visual Studio Guidance Automation Toolkit, Developer Documentation and Help System, and Visual Studio Editor.  I will move your thread to correct forum.

    Best regards,

    Joyce


    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, July 18, 2017 2:42 AM
  • Do I change the Access field type then change the adaptor?  What is the easiest way to do this?

    Hi Roy,

    First I have to say that I have not used BE database, your mean that you change field type in BE database or using VB.net code to change?

    About some operation in Be database, please refer to:

    https://social.technet.microsoft.com/Forums/office/en-US/home?forum=winservergen

    For me, I usually change access field type, and then change adaptor. About easiest way, it depends on your project needs.

    Best Regards,

    Cherry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Tuesday, July 18, 2017 2:52 AM
  • The Access database stats the DB. 

    Therefore change the files in the DB and then click on the DataSet XML to set that in the pane. Then right click on it in the pane (not in solution explorer) and select config. 


    Success
    Cor

    Tuesday, July 18, 2017 6:38 AM
  • If you are using a TableAdapter then yes I would use Microsoft Access to change data type of the field in the table. It should warn you if any truncation or change in the existing data occurs. After the modifying the data type it would probably be easier just to recreate the TableAdapter, rather than trying to edit it.

    Paul ~~~~ Microsoft MVP (Visual Basic)

    • Proposed as answer by Reed KimbleMVP Tuesday, July 18, 2017 12:45 PM
    Tuesday, July 18, 2017 11:14 AM